home *** CD-ROM | disk | FTP | other *** search
/ Monster Media 1994 #2 / Monster Media No. 2 (Monster Media)(1994).ISO / prog_pas / rkey31tp.zip / REGKEY.TXT < prev    next >
Text File  |  1994-06-05  |  211KB  |  4,706 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  
  12.  
  13.                                                                    R E G K E Y
  14.  
  15.  -----------------------------------------------------------------------------
  16.  
  17.  
  18.                                                                   Version 3.10
  19.  
  20.  
  21.                                        Registration Key System For Programmers
  22.  
  23.  
  24.                                                            Programmer's Manual
  25.  
  26.  
  27.  
  28.  
  29.  
  30.  
  31.  
  32.  
  33.  
  34.  
  35.  
  36.  
  37.  
  38.  
  39.  
  40.  
  41.  
  42.  
  43.  
  44.  
  45.  
  46.  
  47.  NOTE:     Since you will probably want to refer to this manual while  working
  48.            with RegKey, it would be a good idea to take a few minutes to print
  49.            it.  To  print  this  manual  on  any  printer,  simply  type  COPY
  50.            REGKEY.TXT PRN from the DOS Prompt, or choose the FILE|PRINT option
  51.            from the Windows File Manager, selecting the REGKEY.TXT file.
  52.  
  53.  
  54.  
  55.  
  56.  
  57.           (C) Copyright Brian Pirie, 1993 - 1994. All Rights Reserved.
  58.  
  59.  
  60.  -----------------------------------------------------------------------------
  61.  TABLE OF CONTENTS
  62.  -----------------------------------------------------------------------------
  63.  
  64.  
  65.            TABLE OF CONTENTS.................................................2
  66.  
  67.            PART 1: INTRODUCTION..............................................3
  68.  
  69.            PART 2: ABOUT YOUR EVALUATION COPY AND REGISTERING................5
  70.                 THE DEMO VERSION & BENEFITS OF REGISTERING...................5
  71.                 HOW TO ORDER.................................................7
  72.                 FILLING OUT THE REGISTRATION FORM............................8
  73.                 RECEIVING YOUR ORDER BY CONVENTIONAL MAIL....................8
  74.                 RECEIVING YOUR ORDER BY A CALL TO YOUR BBS...................9
  75.                 RECEIVING YOUR ORDER BY CALLING THE REGKEY BBS...............9
  76.                 RECEIVING YOUR ORDER BY INTERNET EMAIL.......................9
  77.                 RECEIVING YOUR ORDER BY FIDONET CRASHMAIL...................10
  78.                 SENDING YOUR ORDER FEE......................................11
  79.                 ORDERING THE SOURCE CODE....................................13
  80.                 REGKEY 3.10 ORDER FORM......................................15
  81.                 REGKEY 3.10 USER FEEDBACK FORM..............................16
  82.                 TERMS OF REGISTRATION AND SOURCE CODE USE...................17
  83.  
  84.            PART 3: USING THE REGKEY SYSTEM..................................18
  85.                 A QUICK TOUR OF REGKEY......................................18
  86.                 INTRODUCTION TO REGISTRATION KEYS...........................21
  87.                 PRINCIPLES OF THE REGKEY SYSTEM.............................23
  88.                 FILE-BASED VS. USER-ENTERED REGISTRATION KEYS...............25
  89.                 USING THE KEYGEN PROGRAM....................................27
  90.                 CREATING GENERATION/VALIDATION CODE SETS....................29
  91.                 GENERATING REGISTRATION KEYS................................31
  92.                 VALIDATING REGISTRATION KEYS WITHIN YOUR PROGRAM............34
  93.                 METHODS FOR ADDING EXPIRY INFORMATION.......................37
  94.                 SECURITY ISSUES.............................................40
  95.                 TROUBLESHOOTING GUIDE.......................................44
  96.  
  97.            PART 4: LANGUAGE-SPECIFIC INFORMATION............................47
  98.                 USING THE REGKEY SYSTEM WITH C OR C++.......................47
  99.                 USING THE REGKEY SYSTEM WITH QUICKBASIC.....................56
  100.                 USING THE REGKEY SYSTEM WITH VISUAL BASIC...................62
  101.                 USING THE REGKEY SYSTEM WITH TURBO PASCAL...................63
  102.                 USING REGKEY WITH OTHER LANGUAGES OR OPERATING SYSTEMS......70
  103.  
  104.            PART 5: ADDITIONAL INFORMATION...................................71
  105.                 GETTING HELP................................................71
  106.                 CONTENTS OF PACKAGE.........................................73
  107.                 REVISION HISTORY............................................76
  108.                 GLOSSARY....................................................78
  109.                 INDEX.......................................................83
  110.  
  111.  
  112.  -----------------------------------------------------------------------------
  113.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 2
  114.  
  115.  
  116.  -----------------------------------------------------------------------------
  117.  PART 1: INTRODUCTION
  118.  -----------------------------------------------------------------------------
  119.  
  120.  **NOTE**  RegKey is now distributed in separate packages for each programming
  121.            language.   Be  sure  that  you  have   the  RegKey  package  which
  122.            corresponds to the  programming language  that you  are using.  For
  123.            information  on obtaining  the newest  version of any of the RegKey
  124.            packages, please see page 71.
  125.  
  126.                 RKEY31C.ZIP    C/C++ (DOS & Windows) version of RegKey
  127.                 RKEY31TP.ZIP   Turbo Pascal (DOS & Windows) version of RegKey
  128.                 RKEY31QB.ZIP   QuickBASIC version of RegKey
  129.                 RKEY31VB.ZIP   VisualBasic (Windows) version of RegKey
  130.  
  131.  
  132.            Welcome to  RegKey, the  registration key  system for  programmers!
  133.            RegKey is designed to allow you to quickly and easily add  advanced
  134.            registration  key  capabilities  to  your  software.  If  you   are
  135.            unfamiliar with the concept  of registration keys,  see page 20  of
  136.            this manual for an introduction to the subject.
  137.  
  138.            Among the unique features provided by RegKey are the following:
  139.  
  140.           -  RegKey  is  compatible  with  a  wide   variety  of  programming
  141.              languages and operating  systems. This manual  provides specific
  142.              instructions for using RegKey  with C compilers  from Microsoft,
  143.              Borland and Mix Software (for both  DOS and Windows applications
  144.              when supported by the compiler), Microsoft QuickBASIC, Microsoft
  145.              Visual Basic for Windows, and Borland Turbo Pascal (both DOS and
  146.              Windows versions). In  addition, you  can also  use RegKey  with
  147.              many  other  programming  languages,   compilers  and  operating
  148.              systems. For more  information on  using RegKey  in environments
  149.              not explicitly discussed in this manual, see page 70.
  150.  
  151.           -  RegKey is  designed to  be very  flexible. For  instance, RegKey
  152.              supports both file-based and user-entered  registration keys. In
  153.              the first case, the registration  key takes the form  of a small
  154.              file that is placed in your  application's working directory. In
  155.              the second case, the registration key takes the form of a twenty
  156.              digit code  that  the  user  enters  into  your  application  or
  157.              configuration program.
  158.  
  159.              RegKey also gives  you full control  of any differences  in your
  160.              application's  behavior  between  registered   and  unregistered
  161.              modes. For  example,  you may  elect  to  have your  application
  162.              display a  short  "please  register"  message  at  startup  when
  163.              operating in unregistered mode. Alternatively, you may decide to
  164.              make additional feature of your program available after the user
  165.              has registered. You might also decide  prevent your program from
  166.  
  167.  
  168.  -----------------------------------------------------------------------------
  169.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 3
  170.  
  171.  
  172.              being  used  after  a   certain  period  of  time   if  a  valid
  173.              registration key has not been provided.
  174.  
  175.           -  Every application  that  uses  RegKey  chooses  its own  set  of
  176.              numerical codes  that  RegKey  uses  to  generate  and  validate
  177.              registration keys. This  means that  you can  use RegKey  for as
  178.              many different  applications as  you  wish, requiring  different
  179.              registration keys for each program.
  180.  
  181.           -  RegKey is  designed  so  that  it  is virtually  impossible  for
  182.              someone to  generate  counterfeit  registration  keys  for  your
  183.              software.  The   numerical  code   required  to   generate  your
  184.              registration keys is different from the  corresponding code used
  185.              to validate your  registration keys.  Since only  the validation
  186.              code is included in  your program's executable file,  the secret
  187.              numerical code used to generate your registration keys cannot be
  188.              discovered  by   reverse-engineering   your   program.   It   is
  189.              mathematically  infeasible   for  someone   to  determine   your
  190.              generation code from the corresponding validation code.
  191.  
  192.           -  For  added  security,  RegKey  uses  96-bit  registration  keys.
  193.              Because most  compilers and  programming languages  only support
  194.              32-bit arithmetic, registration keys  are most often  no greater
  195.              than 32-bits in size.  While creating a registration  key system
  196.              that supports 96-bit registration  keys involves much  more work
  197.              (creating  RegKey  has  involved  writing  routines  to  perform
  198.              operations as  basic  as adding,  multiplying  and dividing  two
  199.              numbers), it  makes  it  virtually  impossible  to  determine  a
  200.              registration key by an exhaustive search.
  201.  
  202.           -  The source code for  RegKey is also available.  This presents no
  203.              security threat to those using  RegKey due to the  nature of the
  204.              algorithms used  by RegKey.  Even knowing  how  RegKey works  in
  205.              great detail does not make it any easier to generate counterfeit
  206.              registration keys for an application using RegKey.
  207.  
  208.           -  Included with RegKey is an example program that demonstrates how
  209.              you can make use of the RegKey system. This manual also provides
  210.              a tutorial on how you can best use RegKey, and discusses some of
  211.              the issues you may want to consider.
  212.  
  213.           -  RegKey is very low-priced.  For only $30  Canadian Dollars,  $24
  214.              U.S. Dollars, or your country's equivalent,  you are entitled to
  215.              unlimited use of this and all future versions  of RegKey. For an
  216.              additional $30CDN/$24US/equivalent,  you  may  also receive  the
  217.              RegKey source code.
  218.  
  219.              If you  are using  RegKey to  encourage people  to pay  for your
  220.              software, RegKey will quickly pay for itself!
  221.  
  222.  
  223.  
  224.  -----------------------------------------------------------------------------
  225.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 4
  226.  
  227.  
  228.  -----------------------------------------------------------------------------
  229.  PART 2: ABOUT YOUR EVALUATION COPY AND REGISTERING
  230.  -----------------------------------------------------------------------------
  231.  
  232.  
  233.  
  234.  THE DEMO VERSION & BENEFITS OF REGISTERING
  235.  -----------------------------------------------------------------------------
  236.  
  237.            RegKey is distributed on a try-before-you-buy basis. If you wish to
  238.            continue using RegKey after an initial one month evaluation period,
  239.            or if you wish to distribute programs using RegKey, you must pay to
  240.            register it.
  241.  
  242.            The complete  RegKey  package is  freely  distributed, and  can  be
  243.            freely  used  for  evaluation   purposes.  All  the  features   and
  244.            capabilities of RegKey are enabled in  the RegKey package that  you
  245.            have. However, prior to registering, you may only use RegKey  under
  246.            the following conditions:
  247.  
  248.           1.) RegKey may only  be used for a period up to one month,  and only
  249.               for evaluation purposes prior to registering.
  250.  
  251.           2.) Programs using  an  unregistered  copy  of  RegKey  may  not  be
  252.               distributed.
  253.  
  254.            Also, when unregistered, RegKey will display a message to the  user
  255.            indicating that  RegKey  is not  registered.  This message  is,  of
  256.            course, removed when RegKey is registered.
  257.  
  258.            If you decided to purchase RegKey,  you will become the owner of  a
  259.            powerful tool  for adding  registration  key capabilities  to  your
  260.            software. Registered owners of RegKey are entitled to:
  261.  
  262.           1.) Unlimited use of RegKey.  You may write as many programs  as you
  263.               wish using RegKey,  and do what you please with  these programs.
  264.               There are no additional royalty fees for using RegKey.
  265.  
  266.           2.) You will also continue  to be registered for all future versions
  267.               of RegKey for all programming languages.
  268.  
  269.            The best news of all  is the low price  of RegKey. This version  of
  270.            RegKey costs only $30  Canadian Dollars, $24  U.S. Dollars, or  the
  271.            equivalent in your country's currency.  As was pointed out  before,
  272.            if you  are  using RegKey  to  encourage  people to  pay  for  your
  273.            software, RegKey  will quickly  pay for  itself! (This  price  will
  274.            probably go up for  future versions. By  registering now, you  will
  275.            save by being able to use all future versions free of charge.)
  276.  
  277.            Many people also elect to receive  the RegKey source code  package.
  278.            The source code for  RegKey is available  to registered owners  for
  279.  
  280.  -----------------------------------------------------------------------------
  281.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 5
  282.  
  283.  
  284.            only an additional $30 Canadian /  $24 U.S. / equivalent. With  the
  285.            RegKey source code, you will be  able to customize it for your  own
  286.            purposes,  port  it  to  other  operating  systems  or  programming
  287.            languages, learn about how RegKey  works, or increase the  security
  288.            of RegKey  by adding  your own  anti-hacking mechanisms.  For  more
  289.            information on ordering the RegKey source code, see page 13.
  290.  
  291.  
  292.  
  293.  
  294.  
  295.  
  296.  
  297.  
  298.  
  299.  
  300.  
  301.  
  302.  
  303.  
  304.  
  305.  
  306.  
  307.  
  308.  
  309.  
  310.  
  311.  
  312.  
  313.  
  314.  
  315.  
  316.  
  317.  
  318.  
  319.  
  320.  
  321.  
  322.  
  323.  
  324.  
  325.  
  326.  
  327.  
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334.  
  335.  
  336.  -----------------------------------------------------------------------------
  337.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 6
  338.  
  339.  
  340.  HOW TO ORDER
  341.  -----------------------------------------------------------------------------
  342.  
  343.            To order  your  RegKey  registration and/or  source  code  package,
  344.            simply fill out the order form  located on page 15 of this  manual,
  345.            and mail it along  with your cheque or  money order to the  address
  346.            listed on  the order  form. The  following section  is intended  to
  347.            answer any questions that  you may have  about ordering RegKey.  If
  348.            you have  any additional  questions  or  uncertainties  about  your
  349.            registration, please  feel  more  than  free  to  contact  me.  For
  350.            information on  how to  contact  me,  please  see  page 71 of  this
  351.            manual.
  352.  
  353.            For more information on filling out the order form, see page 8.
  354.  
  355.            For more information on sending your order fee, see page 11.
  356.  
  357.            For more information on ordering the source code, see page 13.
  358.  
  359.  
  360.  
  361.  
  362.  
  363.  
  364.  
  365.  
  366.  
  367.  
  368.  
  369.  
  370.  
  371.  
  372.  
  373.  
  374.  
  375.  
  376.  
  377.  
  378.  
  379.  
  380.  
  381.  
  382.  
  383.  
  384.  
  385.  
  386.  
  387.  
  388.  
  389.  
  390.  
  391.  
  392.  -----------------------------------------------------------------------------
  393.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 7
  394.  
  395.  
  396.  FILLING OUT THE REGISTRATION FORM
  397.  -----------------------------------------------------------------------------
  398.  
  399.            If you have printed  the RegKey manual, you  can simply remove  and
  400.            mail the forms on pages 15 and 16.  If you have not already printed
  401.            a copy of the manual, and you have a printer, you can quickly print
  402.            these forms by printing the ORDER.FRM  file included in the  RegKey
  403.            distribution archive. To do this, type COPY ORDER.FRM PRN from your
  404.            DOS prompt. If you are working  with Microsoft Windows, select  the
  405.            ORDER.FRM file and  choose the File|Print  command from within  the
  406.            Windows File Manager.
  407.  
  408.            If you do not have a printer, simply send a handwritten version  of
  409.            the order form.
  410.  
  411.            If you have any special instructions  for me, or anything that  you
  412.            would like to say when you register, feel free to write this on the
  413.            back of the registration form, or on a separate sheet of paper.
  414.  
  415.            When filling out the RegKey registration form, be sure to  indicate
  416.            how you would prefer to receive your RegKey registration key and/or
  417.            source code. The following options are available:
  418.  
  419.           -  Having  me  send   the  registration  and / or source   code   by
  420.              conventional mail
  421.           -  Internet E-Mail
  422.           -  FidoNet "CrashMail"
  423.           -  Having me call to your BBS
  424.           -  You calling the RegKey support BBS
  425.  
  426.            Once you have decided which means you would prefer to receive  your
  427.            order by,  please  read the  detailed  instructions on  your  order
  428.            method, below. Also, if you are ordering the source code, please be
  429.            sure to read the section on ordering the source code, which  begins
  430.            on page 13.
  431.  
  432.  
  433.  
  434.  -----------------------------------------------------------------------------
  435.  RECEIVING YOUR ORDER BY CONVENTIONAL MAIL
  436.  
  437.            To receive  your  RegKey registration  key  and/or source  code  by
  438.            conventional mail, simply fill out the order form and mail it along
  439.            with your payment as described below.
  440.  
  441.            If you are ordering the source code, it will be sent to you on a 3-
  442.            1/2 inch disk unless  you specifically request  a 5-1/4 inch  disk.
  443.            Because of their  smaller size and  greater durability, 3-1/2  inch
  444.            disks are the preferred format for mailing.
  445.  
  446.  
  447.  
  448.  -----------------------------------------------------------------------------
  449.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 8
  450.  
  451.  
  452.  
  453.  -----------------------------------------------------------------------------
  454.  RECEIVING YOUR ORDER BY A CALL TO YOUR BBS
  455.  
  456.            Since many programmers  operate bulletin board  systems to  provide
  457.            support for their software,  you may elect  to receive your  RegKey
  458.            registration and/or source code by a message and/or upload on  your
  459.            BBS. In order to do this, fill out the order form and mail it along
  460.            with your payment as described below. Be sure to include the  phone
  461.            number, baud rate, and my login  and password for the BBS to  which
  462.            you would like me to call. I will cover any long distance costs. If
  463.            for some reason I  am unable to  connect to your  BBS, I will  send
  464.            your order by conventional mail instead.
  465.  
  466.  
  467.  
  468.  -----------------------------------------------------------------------------
  469.  RECEIVING YOUR ORDER BY CALLING THE REGKEY BBS
  470.  
  471.            You may choose  to receive your  RegKey registration and/or  source
  472.            code by calling the RegKey BBS after your registration form     and
  473.            order fee have  been received here.  If you are  unable to  receive
  474.            your order by  any other electronic  means (such as  a call BBS  to
  475.            your BBS, or by electronic mail), this may be the quickest way  for
  476.            you to receive  your registration information  and/or source  code.
  477.            The obvious disadvantage with this option is that you will have  to
  478.            estimate when your order will arrive here in order to receive it as
  479.            quickly as possible.  You may end  up calling the  RegKey BBS  more
  480.            than once before your order has arrived. After your order form  has
  481.            arrived, your registration key and/or source code will be placed on
  482.            hold for you, and you will be able to receive it on your first call
  483.            to the BBS. The phone number of the BBS is:
  484.  
  485.                           +1 613 526 4466
  486.  
  487.  
  488.  
  489.  -----------------------------------------------------------------------------
  490.  RECEIVING YOUR ORDER BY INTERNET EMAIL
  491.  
  492.            If you wish to receive your RegKey registration key by Internet  E-
  493.            Mail (including Internet E-Nail to a CompuServe account), fill  out
  494.            the order form  and mail it  along with your  payment as  described
  495.            below. Be sure to include your  e-mail address on your order  form.
  496.            Note that the source code cannot be sent by Internet e-mail.
  497.  
  498.  
  499.  
  500.  
  501.  
  502.  
  503.  
  504.  -----------------------------------------------------------------------------
  505.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 9
  506.  
  507.  
  508.  
  509.  
  510.  
  511.  -----------------------------------------------------------------------------
  512.  RECEIVING YOUR ORDER BY FIDONET CRASHMAIL
  513.  
  514.            To receive  your  RegKey registration  key  and/or source  code  by
  515.            FidoNet CrashMail, simply fill out the order form and mail it along
  516.            with your  payment  as described  below.  Be sure  to  include  the
  517.            FidoNet node address to  which you wish  to have your  registration
  518.            key and/or source code sent to  (by CrashMail). Again I will  cover
  519.            any long  distance costs.  If,  for some  reason,  I am  unable  to
  520.            connect  to  your  FidoNet  system,  I  will  send  your  order  by
  521.            conventional mail instead.
  522.  
  523.  
  524.  
  525.  
  526.  
  527.  
  528.  
  529.  
  530.  
  531.  
  532.  
  533.  
  534.  
  535.  
  536.  
  537.  
  538.  
  539.  
  540.  
  541.  
  542.  
  543.  
  544.  
  545.  
  546.  
  547.  
  548.  
  549.  
  550.  
  551.  
  552.  
  553.  
  554.  
  555.  
  556.  
  557.  
  558.  
  559.  
  560.  -----------------------------------------------------------------------------
  561.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 10
  562.  
  563.  
  564.  SENDING YOUR ORDER FEE
  565.  -----------------------------------------------------------------------------
  566.  
  567.            The price of  RegKey is 30  Canadian Dollars, 24  U.S. Dollars,  or
  568.            equivalent  for  the  registration.   The  source  code  costs   an
  569.            additional 30 Canadian Dollars, 24 U.S. Dollars, or equivalent. For
  570.            your convenience,  the  equivalent  value  in  a  number  of  other
  571.            country's currencies (at the time of this writing) is listed below:
  572.  
  573.                    -----------------------------------------------
  574.                                             REGISTRATION
  575.                    REGISTRATION ONLY        AND SOURCE CODE
  576.                    -----------------------------------------------
  577.                    30 Canadian Dollars      60 Canadian Dollars
  578.                    24 US Dollars            48 US Dollars
  579.                    15 British Pounds        30 British Pounds
  580.                    130 French Francs        260 French Francs
  581.                    38 German Marks          76 German Marks
  582.                    43 Netherlands Gilders   86 Netherlands Gilders
  583.                    34 Australian Dollars    68 Australian Dollars
  584.                    -----------------------------------------------
  585.  
  586.            This order fee may be paid using any of the following methods:
  587.  
  588.           -  Cheque or  Money  Order  in  Canadian  currency,  drawn  upon  a
  589.              Canadian bank.  In this  case,  your order  fee  will be  either
  590.              $30CDN for  just  the  registration,  or  $60CDN  for  both  the
  591.              registration and source code.
  592.  
  593.           -  Cheque or Money Order in U.S. currency, drawn  upon a U.S. bank.
  594.              In this case, your order fee  will be either $24US  for just the
  595.              registration, or  $48US  for both  the  registration and  source
  596.              code.
  597.  
  598.           -  An  International  Money  Order  or   International  Bank  Draft
  599.              (available from your bank,  post office or organization  such as
  600.              American  Express),  in  Canadian  currency.  Depending  on  the
  601.              particular case, your order fee MAY be sent to  me by the postal
  602.              service, and you will mail your order form by itself. You should
  603.              have the  money  order  drawn  in  either $30CDN  for  just  the
  604.              registration, or  $60CDN for  both the  registration and  source
  605.              code.
  606.  
  607.           -  A cheque  drawn on  any bank  in  the world,  IN THAT  COUNTRY'S
  608.              CURRENCY, equivalent  to  $30  Canadian  dollars  for  just  the
  609.              registration or $60 for  both the registration and  source code.
  610.              For instance,  a cheque  for the  appropriate number  of British
  611.              Pounds, drawn  on  a  British  bank,  is  perfectly  acceptable.
  612.              However, I  am  unable  to  accept  a cheque  for  $30  Canadian
  613.              dollars, drawn on a British Bank.
  614.  
  615.  
  616.  -----------------------------------------------------------------------------
  617.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 11
  618.  
  619.  
  620.           -  Cash.  Cash   orders  are   also  accepted,   but  it   is  your
  621.              responsibility to get that  cash to me safely.  Please note that
  622.              it is not usually recommended that cash be sent in the mail, and
  623.              that I cannot be responsible for any cash lost in the mail.
  624.  
  625.              I would like  to mention that  many people have  already ordered
  626.              RegKey by sending cash, and I have yet to run across any case of
  627.              cash being lost in  the mail. Nonetheless,  if you wish  to send
  628.              cash, you may wish to consider doing so  by registered mail, for
  629.              your added security.
  630.  
  631.  
  632.            If you are ordering RegKey from within Canada, you will most likely
  633.            choose the first option (a Canadian cheque or money order). If  you
  634.            are ordering RegKey from  within the United  States, you will  most
  635.            likely choose  the  second  option (an  American  cheque  or  money
  636.            order). If you are  ordering from outside Canada  and the U.S.,  it
  637.            would be ideal if you could send your fee by an international money
  638.            order. However, any of the above  order methods will be  acceptable
  639.            from any location. Also, it is quite possible that I may be able to
  640.            accept other means  of sending your  order fee. If  you are  unsure
  641.            about sending your order fee, please feel free to get in touch with
  642.            me by any of the means listed on page 71.
  643.  
  644.  
  645.  
  646.  
  647.  
  648.  
  649.  
  650.  
  651.  
  652.  
  653.  
  654.  
  655.  
  656.  
  657.  
  658.  
  659.  
  660.  
  661.  
  662.  
  663.  
  664.  
  665.  
  666.  
  667.  
  668.  
  669.  
  670.  
  671.  
  672.  -----------------------------------------------------------------------------
  673.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 12
  674.  
  675.  
  676.  ORDERING THE SOURCE CODE
  677.  -----------------------------------------------------------------------------
  678.  
  679.            Many people who  register RegKey also  choose to  order the  source
  680.            code package. With  the RegKey  source code,  you will  be able  to
  681.            customize it  for your  own purposes,  port it  to other  operating
  682.            systems or programming languages, learn about how RegKey works,  or
  683.            increase the security of RegKey by adding  your  own "anti-hacking"
  684.            mechanisms.
  685.  
  686.            As mentioned before, the RegKey source  code may be ordered for  an
  687.            additional  $30  Canadian  Dollars,   $24  U.S.  Dollars,  or   the
  688.            equivalent in  your  country's currency.  The  source code  may  be
  689.            ordered either at the same time you register RegKey, or separately.
  690.            If you  wish to  order the  RegKey source  code, simply  check  the
  691.            appropriate box on the order form,  and include the additional  fee
  692.            for ordering  the source  code. When  you order  the RegKey  source
  693.            code, you will receive it either on a diskette, or  electronically,
  694.            depending upon  how you  chose to  receive  your order.  (For  more
  695.            information on these options, see the  section that begins on  page
  696.            8.)
  697.  
  698.            Also, as with your RegKey registration,  when you order the  RegKey
  699.            source code, you are entitled to receive all future versions of the
  700.            source code. Whenever you wish to receive an updated version of the
  701.            source code package,  you can either  download it  from the  RegKey
  702.            support BBS, or send $3 dollars to cover the cost of postage and  a
  703.            diskette to my address.
  704.  
  705.            The RegKey source code package includes  both the core source  code
  706.            of RegKey  itself, and  the source  code for  the DOS  and  Windows
  707.            version of the KeyGen program.  RegKey itself  is written in  ANSI-
  708.            compliant C, and is designed to be easily ported to other platforms
  709.            or operating systems. In addition to the C source code for  RegKey,
  710.            you will receive optimized 80x86 assembly language source code  for
  711.            some of the RegKey routines. Since the equivalent C source code  is
  712.            included for all  assembly language routines,  use of the  assembly
  713.            language source code  is optional. However,  the assembly  language
  714.            routines provide  dramatically  improved  performance.  The  RegKey
  715.            source code has been compiled with C compilers from both  Microsoft
  716.            and Borland. The  source code package  also includes  a basic  test
  717.            program that  exercises various  components  of the  RegKey  source
  718.            code, and can help you in locating problems when porting RegKey to
  719.            other platforms.
  720.  
  721.            The KeyGen source code is  divided into  three components  - a core
  722.            module common to both DOS and Windows version, a module  containing
  723.            the DOS-specific  interface  code,  and  a  module  containing  the
  724.            Windows-specific interface  code. The  source code  for the  common
  725.            module is  again  written  in ANSI-compliant  C.  The  DOS-specific
  726.            interface code is  also written in  ANSI-compliant C, but  contains
  727.  
  728.  -----------------------------------------------------------------------------
  729.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 13
  730.  
  731.  
  732.            many MS-DOS specific elements. The Windows-specific interface  code
  733.            is written  in C++,  and uses  the "Microsoft  Foundation  Classes"
  734.            interface to the Windows operating system. The Microsoft Foundation
  735.            Classes  library  is  included  with  recent  C++  compilers   from
  736.            Microsoft and others.
  737.  
  738.            For information on  what you are  permitted to do  with the  RegKey
  739.            source code, see the terms and conditions on page 17.
  740.  
  741.  
  742.  
  743.  
  744.  
  745.  
  746.  
  747.  
  748.  
  749.  
  750.  
  751.  
  752.  
  753.  
  754.  
  755.  
  756.  
  757.  
  758.  
  759.  
  760.  
  761.  
  762.  
  763.  
  764.  
  765.  
  766.  
  767.  
  768.  
  769.  
  770.  
  771.  
  772.  
  773.  
  774.  
  775.  
  776.  
  777.  
  778.  
  779.  
  780.  
  781.  
  782.  
  783.  
  784.  -----------------------------------------------------------------------------
  785.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 14
  786.  
  787.  
  788.  --------------------------------------------------------------------------
  789.                             REGKEY 3.10 ORDER FORM
  790.  --------------------------------------------------------------------------
  791.  
  792.           YOUR NAME : _______________________________   (AS SHOULD APPEAR IN
  793.                                                          REGISTRATION)
  794.      POSTAL ADDRESS : ______________________________________________________
  795.  
  796.                       ______________________________________________________
  797.  
  798.  VOICE PHONE NUMBER : ______________________
  799.  
  800.     EMAIL ADDRESSES : ____________________________________   (IF APPLICABLE)
  801.  
  802.  
  803.  I WISH TO RECEIVE MY ORDER BY:
  804.            ___                                ___
  805.           |   | - CONVENTIONAL MAIL          |   | - FIDONET "CRASHMAIL"
  806.           |___|                              |___|
  807.            ___                                ___
  808.           |   | - CALL TO MY BBS             |   | - INTERNET E-MAIL
  809.           |___|   (INCLUDE NECESSARY INFO)   |___|   (REGISTRATION KEY ONLY)
  810.            ___
  811.           |   | - CALL TO REGKEY BBS
  812.           |___|
  813.  
  814.                          ___
  815.  I WOULD LIKE TO ORDER: |   | - JUST MY REGISTRATION KEY
  816.                         |___|   ($30 CDN, $24US, OR EQUIVALENT)
  817.                          ___
  818.                         |   | - JUST THE SOURCE CODE (ONLY IF ALREADY
  819.                         |___|   REGISTERED) ($30 CDN, $24 US, OR EQUIVALENT)
  820.                          ___
  821.                         |   | - BOTH REGISTRATION KEY AND SOURCE CODE
  822.                         |___|   ($60 CDN, $48 US, OR EQUIVALENT)
  823.  
  824.  
  825.  I AGREE TO THE REGKEY TERMS, SET              ____________________________
  826.  FORTH ON PAGE 17 OF THE MANUAL                (SIGNATURE)
  827.  
  828.  MAKE CHEQUES PAYABLE TO:   BRIAN PIRIE
  829.                             APT. 1416 - 2201 RIVERSIDE DR.
  830.                             OTTAWA, ONTARIO
  831.                             CANADA
  832.                             K1H 8K9
  833.  
  834.  +-- OFFICIAL USE ONLY ---------------------------------------------- TP --+
  835.  |                                                                         |
  836.  | Rcvd : _______  Date : _________  S.N. : _________  Key : _____________ |
  837.  +-------------------------------------------------------------------------+
  838.  
  839.  
  840.  -----------------------------------------------------------------------------
  841.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 15
  842.  
  843.  
  844.  --------------------------------------------------------------------------
  845.                         REGKEY 3.10 USER FEEDBACK FORM
  846.  --------------------------------------------------------------------------
  847.  
  848.           YOUR NAME : _______________________________
  849.  
  850.      POSTAL ADDRESS : ______________________________________________________
  851.  
  852.                       ______________________________________________________
  853.  
  854.  VOICE PHONE NUMBER : ______________________
  855.  
  856.     EMAIL ADDRESSES : ____________________________________   (IF APPLICABLE)
  857.  
  858.  
  859.  HOW DID YOU FIRST LEARN OF OR RECEIVE REGKEY?
  860.  
  861.               ____________________________________________________________
  862.  
  863.  
  864.  WHICH LANGUAGE / COMPILER AND VERSION ARE YOU USING?  (EG. BORLAND C++ 3.10)
  865.  
  866.               ____________________________________________________________
  867.  
  868.  
  869.  WHAT DO YOU LIKE MOST ABOUT REGKEY?
  870.  
  871.               ____________________________________________________________
  872.  
  873.               ____________________________________________________________
  874.  
  875.               ____________________________________________________________
  876.  
  877.  
  878.  WHAT CHANGES OR ADDITIONS WOULD YOU LIKE TO SEE IN FUTURE VERSIONS?
  879.  
  880.               ____________________________________________________________
  881.  
  882.               ____________________________________________________________
  883.  
  884.               ____________________________________________________________
  885.  
  886.  
  887.  DO YOU HAVE ANY ADDITIONAL COMMENTS?
  888.  
  889.               ____________________________________________________________
  890.  
  891.               ____________________________________________________________
  892.  
  893.  
  894.  ----------------------------------------------------------------------------
  895.  
  896.  -----------------------------------------------------------------------------
  897.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 16
  898.  
  899.  
  900.  TERMS OF REGISTRATION AND SOURCE CODE USE
  901.  -----------------------------------------------------------------------------
  902.  
  903.            When you purchase a RegKey registration and/or source code package,
  904.            you are entitled to almost unlimited use of all versions of RegKey.
  905.            However, in order to  protect my investment of  time and effort  in
  906.            developing RegKey, you must also agree to the terms outlined  below
  907.            when purchasing a RegKey registration and/or the source code. These
  908.            terms are very reasonable,  and are in no  way intended to  cripple
  909.            your use of RegKey. The primary  intent of these terms is that  you
  910.            are not permitted to disclose your RegKey registration information,
  911.            or the  RegKey source  code, to  other  individuals. The  terms  of
  912.            registration and source code use are as follows:
  913.  
  914.            For the  purpose of  these terms,  "RegKey" is  defined to  be  the
  915.            library files,  header  files, example  programs  and  programmer's
  916.            manual of all versions, present and  future, for all languages  and
  917.            platforms, of the RegKey registration key system. Upon  registering
  918.            RegKey, the individual  or organization named  on the  registration
  919.            form (the registree) is entitled to use of all versions of  RegKey,
  920.            within the terms set forth below. Violation of these terms will  be
  921.            considered copyright infringement, and grounds for the  termination
  922.            of the registration  agreement. The  registree is  entitled, at  no
  923.            additional cost, to use, distribute  or sell the executable  (.EXE,
  924.            .COM, .DLL) files that  result from using  the RegKey toolkit.  The
  925.            registree is also entitled to use,  distribute or sell the  example
  926.            programs or portions  thereof. If purchasing  the source code,  the
  927.            registree is also entitled to distribute any executable files  that
  928.            result from using altered versions of the source code, or  portions
  929.            thereof.  The  registree   is  NOT  entitled   to  distribute   the
  930.            registration key number presented  to them at registration,  except
  931.            when imbedded  in the  executable files  of  a program  which  uses
  932.            RegKey. The registree is not permitted to distribute any portion of
  933.            the RegKey  source  code.  For the  purposes  of  these  terms,  an
  934.            organization  is  considered   to  be  a   company  or   non-profit
  935.            organization. If the registree is an organization, the registration
  936.            key  and  source  code   may  be  shared   among  members  of   the
  937.            organization, under the condition that these individuals are  using
  938.            the registration and/or source code only for official activities of
  939.            that organization.
  940.  
  941.            These terms in  no way suggest  an agreement on  the part of  Brian
  942.            Pirie to develop any future versions of RegKey, or fix any problems
  943.            in current versions of  RegKey. RegKey is offered  "as is", and  no
  944.            warrantees are expressed or implied. In no event shall Brian  Pirie
  945.            be liable for any loss of profit or any other damage, including but
  946.            not limited to special, incidental, consequential or other damages.
  947.            This means  that it  is solely  the registree's  responsibility  to
  948.            determine  the   suitability   of  RegKey   for   the   registree's
  949.            application(s).  This  also  means  that  no  guarantees  are  made
  950.            concerning the portability or compatibility of the RegKey system.
  951.  
  952.  -----------------------------------------------------------------------------
  953.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 17
  954.  
  955.  
  956.  -----------------------------------------------------------------------------
  957.  PART 3: USING THE REGKEY SYSTEM
  958.  -----------------------------------------------------------------------------
  959.  
  960.  
  961.  
  962.            This portion of the manual  contains information about RegKey  that
  963.            is common to  all languages  supported by  RegKey. Part  4 of  this
  964.            manual, which begins on page  47, provides information specific  to
  965.            each programming language supported by RegKey.
  966.  
  967.            The following sections describe the basic principles of the  RegKey
  968.            system, provide  step-by-step  information on  how  to  incorporate
  969.            RegKey into your applications, and discuss some of the issues  that
  970.            you will want to  consider when using  RegKey. This information  is
  971.            divided into the following sections:
  972.  
  973.                 A Quick Tour of RegKey......................................18
  974.                 Introduction to Registration Keys...........................20
  975.                 Principles of the RegKey System.............................23
  976.                 File-Based vs. User-Entered Registration Keys...............25
  977.                 Using the KeyGen program....................................27
  978.                 Creating Generation/Validation Code Sets....................29
  979.                 Generating Registration Keys................................31
  980.                 Validating Registration Keys................................34
  981.                 Methods for Adding Expiry Information.......................37
  982.                 Security Issues.............................................40
  983.  
  984.  
  985.  
  986.  A QUICK TOUR OF REGKEY
  987.  -----------------------------------------------------------------------------
  988.  
  989.            This section provides a quick overview  of the RegKey package,  and
  990.            is intended  for those  who want  to see  RegKey in  action  before
  991.            reading the detailed  information in the  following sections.  This
  992.            section does not attempt to explain  the use of the RegKey  package
  993.            in detail, but simply guides you on a tour of some of the  programs
  994.            and files included in the RegKey package. If at any point you  want
  995.            to learn more about RegKey, or  are having trouble understanding  a
  996.            particular concept, you can skip to the following sections of  this
  997.            manual for a more detailed tutorial. You may also find the glossary
  998.            on page 78 and the troubleshooting guide on page 44 useful.
  999.  
  1000.            The  RegKey   package   provides  two   distinct   facilities   for
  1001.            implementing registration keys within your applications. The  first
  1002.            facility is used for generating registration keys, typically when a
  1003.            user purchases your software. This facility is generally used  only
  1004.            by yourself  or those  responsible  for selling  your  application.
  1005.            Registration  keys  can  be  generated  using  the  KeyGen  utility
  1006.  
  1007.  
  1008.  -----------------------------------------------------------------------------
  1009.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 18
  1010.  
  1011.  
  1012.            included in the RegKey package, or  you may write a custom  program
  1013.            to manage the generation of registration keys.
  1014.  
  1015.            The second facility  provided by RegKey  is incorporated into  your
  1016.            program itself, and is used to  check the validity of  registration
  1017.            keys at  run  time. Although  the  details of  this  facility  vary
  1018.            depending upon the programming language you are using, they  always
  1019.            involve calling  a  RegKey  function/procedure  that  performs  the
  1020.            actual registration key validation. You are then able to adjust the
  1021.            behavior of  your program  depending upon  the result  returned  by
  1022.            RegKey. This provides you with the  option of displaying a  special
  1023.            message when the user is not registered, disabling certain features
  1024.            when operating in unregistered "demo" mode, or limiting the  length
  1025.            of time someone may use your software before paying for it.
  1026.  
  1027.            Included with RegKey is a very simple demonstration program,  named
  1028.            DemoApp, which  allows you  to test  RegKey and  learn how  to  use
  1029.            RegKey within your own programs.  The RegKey package includes  both
  1030.            MS-DOS and MS-Windows executable versions of DemoApp - DEMOAPPD.EXE
  1031.            and DEMOAPPW.EXE. The RegKey  package also includes the  equivalent
  1032.            source code for DemoApp in the C, C++, Turbo Pascal, QuickBASIC and
  1033.            Visual Basic languages.  To  get a  better  idea  of  how  RegKey's
  1034.            registration key validation facility can be incorporated into  your
  1035.            program, have a look at the version of the DemoApp source code  for
  1036.            the language  you are  most familiar  with.  Also, you  should  try
  1037.            running DemoApp  to  see  how it  behaves  before  you  generate  a
  1038.            registration key for it.
  1039.  
  1040.            As mentioned  before, you  can  generate RegKey  registration  keys
  1041.            using the KeyGen utility.  To start the DOS version of KeyGen, type
  1042.            the KEYGEND  command  at  the DOS  prompt,  while  located  in  the
  1043.            directory where  you have  placed the  RegKey files.  To start  the
  1044.            Windows version of KeyGen, you can double-click on the  KEYGENW.EXE
  1045.            file from within  the Windows File  Manager. If you  are using  the
  1046.            Windows version of KeyGen, the  included CTL3DV2.DLL file should be
  1047.            MOVED to your Windows system directory.  (You may also wish to  add
  1048.            KeyGen  to  a  group  within  the  Windows  Program  Manager.   For
  1049.            instructions on how to do this, see page 27.) Once you have started
  1050.            the KeyGen program, you will see  a list of applications for  which
  1051.            you can generate a registration key.  Initially, there should be  a
  1052.            single application listed:  "DemoApp (RegKey  Example Program".  To
  1053.            generate a registration key for DemoApp, simply select it from  the
  1054.            list of  applications,  and choose  the  "Generate Key"  option.  A
  1055.            second  dialog  box  will  appear,  with  which  you  can   provide
  1056.            information on the registration key to generate. Enter your name as
  1057.            the "Registration String", and enter any combination of 10  numbers
  1058.            and upper-case letters as the "Random Seed". "Registration  String"
  1059.            is usually  the name  of the  individual or  organization that  has
  1060.            purchased your software. The "Random Seed" is used by RegKey during
  1061.            the registration key generation process, and is then discarded. You
  1062.            should enter a different random seed  for each key you  generation.
  1063.  
  1064.  -----------------------------------------------------------------------------
  1065.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 19
  1066.  
  1067.  
  1068.            To generate a  registration key  for DemoApp,  you do  not need  to
  1069.            change any other options in the key generation dialog box. When you
  1070.            select "OK",  KeyGen  will generate  a  registration key  file  for
  1071.            DemoApp, and will then ask you whether you wish to generate another
  1072.            registration key.
  1073.  
  1074.            RegKey   supports   both    file-based   and    user-entered-string
  1075.            registration  keys.   With   file-based  registration   keys,   the
  1076.            registered user receives a small "key file" which is recognized and
  1077.            read by the application at run-time, in order to determine  whether
  1078.            to operate in registered  mode. With user-entered-string keys,  the
  1079.            user enters their  name and a  20 digit registration  key into  the
  1080.            application, which causes it to operate in registered mode.
  1081.  
  1082.            The DemoApp example  program included with  RegKey uses  file-based
  1083.            registration keys. Now that you  have generated a registration  key
  1084.            file for RegKey, you can try running DemoApp again. Ensure that the
  1085.            newly generated key file,  (named ????????.KEY, unless you  changed
  1086.            the default option in the key generation dialog box), is located in
  1087.            the default  directory before  staring  DemoApp. DemoApp  will  now
  1088.            operate in registered  mode, and will  display the registered  user
  1089.            name you entered when generating the registration key.
  1090.  
  1091.            Congratulations! You  have  successfully  completed  your  tour  of
  1092.            RegKey. The  following  sections  provide you  with  more  detailed
  1093.            information on  using  RegKey,  and  part  4  provides  information
  1094.            specific to using RegKey with each of the supported languages.
  1095.  
  1096.  
  1097.  
  1098.  
  1099.  
  1100.  
  1101.  
  1102.  
  1103.  
  1104.  
  1105.  
  1106.  
  1107.  
  1108.  
  1109.  
  1110.  
  1111.  
  1112.  
  1113.  
  1114.  
  1115.  
  1116.  
  1117.  
  1118.  
  1119.  
  1120.  -----------------------------------------------------------------------------
  1121.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 20
  1122.  
  1123.  
  1124.  INTRODUCTION TO REGISTRATION KEYS
  1125.  -----------------------------------------------------------------------------
  1126.  
  1127.            This section  provides an  introduction  to registration  keys  for
  1128.            those who  are unfamiliar  with the  concept.  If you  are  already
  1129.            familiar with the notion behind registration keys, you may wish  to
  1130.            proceed  to  the  following  section,  "Principles  of  the  RegKey
  1131.            System", on page 23.
  1132.  
  1133.            Registration keys are  a form of  software protection;  they are  a
  1134.            mechanism to  encourage users  to pay  for  your software  or  even
  1135.            prevent them from using it without paying for it. Registration keys
  1136.            are often used as  an only means  of software protection,  although
  1137.            they can  easily  be  combined  with  other  mechanisms  for  added
  1138.            security  and  effectiveness.  Unlike   other  forms  of   software
  1139.            protection, such  as software  copy  protection or  hardware  keys,
  1140.            registration keys are ideal  for shareware or  "try-before-you-buy"
  1141.            software.  Using  registration  keys,  you  have  the  ability   to
  1142.            distribute a single copy of your  software that serves as both  the
  1143.            demonstration version and "full" version.
  1144.  
  1145.            The idea behind registration keys is  simple. When a customer  pays
  1146.            for your software, they receive a registration key - either in  the
  1147.            form of a small additional file or a numeric code - which  switches
  1148.            the  software  into  registered   mode.  The  differences   between
  1149.            registered and unregistered  modes can  be as  insignificant or  as
  1150.            great as  you choose.  The software  may simply  display a  "please
  1151.            register" message when unregistered,  it may only  work for a short
  1152.            evaluation period prior to registering, additional features may  be
  1153.            enabled after registering,  or the software  may refuse to  operate
  1154.            entirely before registration.
  1155.  
  1156.            While the  use  of  registration key  systems  is  not  limited  to
  1157.            shareware applications, this  is where registration  keys are  most
  1158.            often used. Many  of the advantages  of the  shareware approach  to
  1159.            software marketing are obvious  - the user  has the opportunity  to
  1160.            try the software before buying it, the software producer is able to
  1161.            reach a wide  audience of potential  customers, and it  is often  a
  1162.            low-cost approach to software marketing. In general, there are  two
  1163.            approaches to shareware marketing. In the first approach, a special
  1164.            demonstration version  of the  software  is freely  distributed  to
  1165.            users,  and  when  the  user  registers  they  receive  the  "full"
  1166.            registered version  of  the  software. With  the  registration  key
  1167.            approach, only  one  version  of the  software  is  released.  This
  1168.            version  normally  operates  in  "unregistered"  or  "demo"   mode.
  1169.            However, when  the  user pays  for  the software,  they  receive  a
  1170.            registration key which  immediately causes the  software to  switch
  1171.            into "registered" mode. Of  these two approaches, the  registration
  1172.            key approach has become very popular for a number of reasons:
  1173.  
  1174.  
  1175.  
  1176.  -----------------------------------------------------------------------------
  1177.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 21
  1178.  
  1179.  
  1180.           -  It has proven highly effective in encouraging  people to pay for
  1181.              the software.
  1182.  
  1183.           -  Since the registration  key is associated  with a  single user's
  1184.              name, it discourages illegal sharing of the registration. People
  1185.              are more  likely to  give away  a copy  of a  generic registered
  1186.              version of the software than they are  to share the registration
  1187.              key that  is associated  with only  their name.  Although it  is
  1188.              possible to  "brand" each  registered copy  of the  software for
  1189.              each user who registers, this often proves to be a great deal of
  1190.              work.
  1191.  
  1192.           -  Registration keys enable the user to  easily switch the software
  1193.              into  registered  mode  upon  registering,   without  having  to
  1194.              reinstall a registered version of the software.
  1195.  
  1196.           -  Registration keys also  allow the option  of upgrading to  a new
  1197.              version by receiving  a widely available  copy of  the software,
  1198.              rather than  having to  receive a  new registered  copy directly
  1199.              from the author.
  1200.  
  1201.           -  If user-entered registration  keys are used  (see page  25 for a
  1202.              comparison  between  user-entered  and  file-based  registration
  1203.              keys), the registration  key can be  quickly transmitted  to the
  1204.              user by  phone, email,  fax or  conventional  mail, rather  than
  1205.              sending a registered version of the entire software package.
  1206.  
  1207.            In addition  to shareware applications,  registration  keys  can be
  1208.            useful  for  many  other  software  protection  applications.   For
  1209.            instance, registration keys can be used in implementing pay-per-use
  1210.            software, where a  new registration key  is sent to  the user  when
  1211.            they pay for additional use of the software. Registration keys  can
  1212.            also be just as useful in discouraging the copying of non-shareware
  1213.            software  as  it  is  for  encouraging  registration  of  shareware
  1214.            software. Registration keys can also  form the basis of  multi-user
  1215.            site licensing systems. Although this manual cannot explicitly deal
  1216.            with all  of the  potential  uses of  the  RegKey system,  it  does
  1217.            attempt  to  provide  general  information  that  will  be  of  use
  1218.            regardless of how you are using RegKey.
  1219.  
  1220.  
  1221.  
  1222.  
  1223.  
  1224.  
  1225.  
  1226.  
  1227.  
  1228.  
  1229.  
  1230.  
  1231.  
  1232.  -----------------------------------------------------------------------------
  1233.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 22
  1234.  
  1235.  
  1236.  PRINCIPLES OF THE REGKEY SYSTEM
  1237.  -----------------------------------------------------------------------------
  1238.  
  1239.            This  section  provides  an   introduction  to  the  concepts   and
  1240.            terminology used by  RegKey. The remainder  of this manual  assumes
  1241.            that you have read this section.
  1242.  
  1243.            A  registration  string  and  corresponding   registration  key  is
  1244.            associated with each person who pays to register your software. The
  1245.            registration  string   uniquely   identifies  the   individual   or
  1246.            organization that has registered, and may contain other information
  1247.            that should not be tampered with.  In many cases, the  registration
  1248.            string will  only be  the  user's name,  but  it may  also  include
  1249.            information such as the registration's  expiry date or the  version
  1250.            of your software that was registered. (For more help on how to  add
  1251.            expiry information  to  registration  keys, see  the  section  that
  1252.            begins on page  37.) In general, the  registration string contains
  1253.            information that the user knows before registering, for which  your
  1254.            application must be able to recognize your "stamp of approval".
  1255.  
  1256.            One  of  the  key  features  of  RegKey  is  the  fact  that  every
  1257.            application using RegKey  requires different  registration keys;  a
  1258.            particular  user's  registration  key  that  is  accepted  by   one
  1259.            application using RegKey will not work with a different application
  1260.            using RegKey. For each application or version for which you wish to
  1261.            require  different   registration   keys,  a  unique   generation /
  1262.            validation code set is created.  Choosing a different  generation/
  1263.            validation code set  results in different  registration keys  being
  1264.            generated and accepted for the same registration string.
  1265.  
  1266.            The secret generation  code is used  to generate registration  keys
  1267.            for your  applications.  The  generation  code  is  only  known  by
  1268.            yourself or people responsible for generating registration keys for
  1269.            your application; the  generation code would  never appear in  your
  1270.            program's  executable  file(s).   Every  generation   code  has   a
  1271.            corresponding validation code.  This validation code is used during
  1272.            your application's  execution in  order  to determine  whether  the
  1273.            supplied registration string (such  as the user's name) corresponds
  1274.            to the supplied registration key. If the registration key is  valid
  1275.            for the registration string  and validation code, RegKey  indicates
  1276.            to your application that it should operate in registered mode.  The
  1277.            validation code  is  contained  within  your  program's  executable
  1278.            files. Although it  may be  possible to  determine this  validation
  1279.            code by  "hacking" your  program's executable  files, there  is  no
  1280.            known feasible way  to calculate the  generation code knowing  this
  1281.            validation code. Therefore,  knowing the validation  code does  not
  1282.            permit someone to generate  counterfeit registration keys for  your
  1283.            software.
  1284.  
  1285.            The registration string and registration key may either be entered
  1286.            directly into your application by the user, or may both be  stored
  1287.  
  1288.  -----------------------------------------------------------------------------
  1289.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 23
  1290.  
  1291.  
  1292.            in a registration key  file. The first approach  is referred to  as
  1293.            user-entered registration keys, and the second approach is referred
  1294.            to as file-based registration keys.  The following section of  this
  1295.            manual discusses the advantages and disadvantages of each approach.
  1296.  
  1297.            Subsequent  sections  of  this  manual  discuss  how  to  use   the
  1298.            facilities provided  by RegKey  to create  a  generation/validation
  1299.            code set for a new application,  how to generate a registration key
  1300.            for a user when they pay for  your software, and how to use  RegKey
  1301.            to deal with registration keys within your application itself.
  1302.  
  1303.  
  1304.  
  1305.  
  1306.  
  1307.  
  1308.  
  1309.  
  1310.  
  1311.  
  1312.  
  1313.  
  1314.  
  1315.  
  1316.  
  1317.  
  1318.  
  1319.  
  1320.  
  1321.  
  1322.  
  1323.  
  1324.  
  1325.  
  1326.  
  1327.  
  1328.  
  1329.  
  1330.  
  1331.  
  1332.  
  1333.  
  1334.  
  1335.  
  1336.  
  1337.  
  1338.  
  1339.  
  1340.  
  1341.  
  1342.  
  1343.  
  1344.  -----------------------------------------------------------------------------
  1345.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 24
  1346.  
  1347.  
  1348.  FILE-BASED VS. USER-ENTERED REGISTRATION KEYS
  1349.  -----------------------------------------------------------------------------
  1350.  
  1351.            RegKey provides support for two types of registration keys:  "user-
  1352.            entered" and "file-based". For a given application, you must choose
  1353.            which of these two types you wish to use.
  1354.  
  1355.            With user-entered  registration  keys, upon  registering  the  user
  1356.            receives a 20 digit code of numbers and letters, such as:
  1357.  
  1358.                      F8T5CQ7LFVXDY6TSC4QU
  1359.  
  1360.            To avoid confusion when copying  the registration key, RegKey  does
  1361.            not use the letters G, I,  O, S, as they  may be confused with  the
  1362.            numerals 6, 1,  0 and  5. If the  user accidentally  enters any  of
  1363.            these letters in  place of the  corresponding number, RegKey  knows
  1364.            that the  number  was  intended, as  treats  the  letter  as  being
  1365.            equivalent to  the number.  Likewise, RegKey  only uses  upper-case
  1366.            letters when generating registration keys, but is not sensitive  to
  1367.            case when validating registration keys.
  1368.  
  1369.            When they  pay  for your  software,  the user  would  typically  be
  1370.            required to enter  this 20-digit code  along with  their name  (the
  1371.            registration  string)   into  your   application  or  configuration
  1372.            program, for example:
  1373.  
  1374.                           Your Name : Brian Pirie
  1375.               Your Registration Key : F8T5CQ7LFVXDY6TSC4QU
  1376.  
  1377.            This information would  then be stored  by your program  in a  data
  1378.            file, for access when the  program is subsequently executed.  Using
  1379.            RegKey, your  application could  then determine  whether or  not  a
  1380.            valid registration key for the user's name has been presented,  and
  1381.            act accordingly.
  1382.  
  1383.            When file-based registration keys are used, rather than receiving a
  1384.            20 digit code, the user receives  a file in electronic form,  which
  1385.            they either manually copy  to the application's working  directory,
  1386.            or install using  a simple installation  program that you  provide.
  1387.            When your application executes, it would  then call upon RegKey  to
  1388.            read this file and  determine whether or  not a valid  registration
  1389.            key file is present. If RegKey indicates that this file is  present
  1390.            and valid, your program would know to operate in registered mode.
  1391.  
  1392.            User-entered and file-base registration keys each provide different
  1393.            advantages and disadvantages.  User-entered registration keys  have
  1394.            the advantage that no disk or  electronic file needs to be sent  to
  1395.            the registered user. This allows you  full flexibility to send  the
  1396.            registration key by conventional  mail, electronic mail,  facsimile
  1397.            or over  the  telephone.  The RegKey  registration  key  format  is
  1398.            specifically designed to be  easy to transmit  by this means.  It's
  1399.  
  1400.  -----------------------------------------------------------------------------
  1401.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 25
  1402.  
  1403.  
  1404.            use of  both  letters and  numbers  makes  it a  very  compact  and
  1405.            efficient  representation  for  the   96-bits  of  information   it
  1406.            contains, while its choice of numbers and upper case letters  helps
  1407.            to reduce the possibility of mis-copying the string.
  1408.  
  1409.            File-based registration keys, on the other hand, may be easier  for
  1410.            the user.  Rather than  having to  enter the  registration key  and
  1411.            related information manually, the user  simply needs to install  an
  1412.            additional small  file. File-based  registration keys  may also  be
  1413.            preferable if  the registration   string contains  more information
  1414.            than simply the user's  name. This might be  the case when you  are
  1415.            imbedding  expiry  information   in  the   registration  string  as
  1416.            described in the section which begins on page 37.
  1417.  
  1418.  
  1419.  
  1420.  
  1421.  
  1422.  
  1423.  
  1424.  
  1425.  
  1426.  
  1427.  
  1428.  
  1429.  
  1430.  
  1431.  
  1432.  
  1433.  
  1434.  
  1435.  
  1436.  
  1437.  
  1438.  
  1439.  
  1440.  
  1441.  
  1442.  
  1443.  
  1444.  
  1445.  
  1446.  
  1447.  
  1448.  
  1449.  
  1450.  
  1451.  
  1452.  
  1453.  
  1454.  
  1455.  
  1456.  -----------------------------------------------------------------------------
  1457.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 26
  1458.  
  1459.  
  1460.  USING THE KEYGEN PROGRAM
  1461.  -----------------------------------------------------------------------------
  1462.  
  1463.            The RegKey  package includes  both DOS  and Windows  versions of  a
  1464.            program called "KeyGen".  KeyGen can  be used  for both creating  a
  1465.            generation/validation  code set  for  a  new  application  and  for
  1466.            quickly generating  registration  keys  for one  or  more  of  your
  1467.            applications.  KeyGen also provides password security facilities to
  1468.            control access to the registration key generation information  that
  1469.            it stores. This section provides some  basic information on how  to
  1470.            setup, maintain  and navigate  through  the KeyGen  program.  Later
  1471.            sections of this  manual provide information  on how to  accomplish
  1472.            specific tasks using  KeyGen, such as  creating a new  code set  or
  1473.            generating a registration key for a new user.
  1474.  
  1475.            To start  the  DOS version  of  KeyGen,  simply  go  to  the RegKey
  1476.            directory and type KEYGEND from the DOS prompt.
  1477.  
  1478.            The Windows version  of KeyGen requires  Microsoft Windows  version
  1479.            3.1 or later. Before using the Windows version of KeyGen, you  must
  1480.            MOVE the  CTL3DV2.DLL file  to your  Windows system  directory.  To
  1481.            start the Windows version of KeyGen, you may simply double-click on
  1482.            the KEYGENW.EXE  file, from  within in  the Windows  File  Manager.
  1483.            KEYGENW.EXE will be located  in the same  directory where you  have
  1484.            placed your other RegKey files.
  1485.  
  1486.            Rather than starting up KeyGen from the Windows file  manager, you
  1487.            may prefer to  add KeyGen to  one of your  Windows program  manager
  1488.            groups. To do this, select the existing group to which you wish  to
  1489.            add KeyGen,  or create  a new  program  manager group.  Now  choose
  1490.            FILE|NEW|PROGRAM  ITEM.  In  the  "Properties"  dialog  box,  enter
  1491.            "KeyGen" as the description, enter the full path to the KEYGENW.EXE
  1492.            file as the command line, and enter the directory where KEYGENW.EXE
  1493.            is located as the working directory. Now choose "OK" to add  KeyGen
  1494.            to the current program manager group. You will now be able to start
  1495.            KeyGen by  double-clicking  on the  KeyGen  icon. The  KeyGen  icon
  1496.            appears as  a diskette  with a  golden key  in front  of it.  (This
  1497.            information applies to using  KeyGen with MS-Windows versions  3.x.
  1498.            If you are  using MS-Windows version  4.0 or later,  refer to  your
  1499.            Windows manual for information  on executing a Windows  application
  1500.            given the filename).
  1501.  
  1502.            If you are using an operating system other and MS-DOS or MS-Windows
  1503.            which has the ability to execute  DOS or Windows programs (such  as
  1504.            OS/2), see your operating system  manual(s) for information on  how
  1505.            to  do  this.  The  filename  of  the  DOS  version  of  KeyGen  is
  1506.            KEYGEND.EXE, and the filename of the  Windows version of KeyGen  is
  1507.            KEYGENW.EXE.
  1508.  
  1509.            The DOS and Windows  versions of KeyGen operate very  similarly  to
  1510.            one another. Both  can be used  with either keyboard  or mouse  (or
  1511.  
  1512.  -----------------------------------------------------------------------------
  1513.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 27
  1514.  
  1515.  
  1516.            similar pointing  device such  as a  trackball  or pen),  and  both
  1517.            provide an identical layout of Windows and dialog boxes. When using
  1518.            a pointing device to navigate through  KeyGen, simply point to  the
  1519.            item you wish to change or activate, and press the pointing  device
  1520.            button. When using a keyboard to  navigate through KeyGen, use  the
  1521.            [Tab] key to move among items,  and press [Enter] or [Spacebar]  to
  1522.            activate items.
  1523.  
  1524.            The DOS and  Windows version  of KeyGen also  share the  same data
  1525.            file, KEYGEN.DAT.  If  you  are relying  on  KeyGen  to  store  the
  1526.            generation/validation code sets for your applications, this file is
  1527.            very sensitive.  Be careful  to control  access to  this file.  You
  1528.            should also be absolutely certain that you maintain backups of this
  1529.            file in the  case of  hardware failure,  fire, accidental  erasure,
  1530.            etc.
  1531.  
  1532.            The main KeyGen window displays a list of applications for which it
  1533.            can generate registration keys. When  you first install the  RegKey
  1534.            package, only  one application  will be  listed -  the RegKey  test
  1535.            program. When you write your own application that uses RegKey,  you
  1536.            can add that program to the list by choosing the "Add  Application"
  1537.            option (see page 29). To generate a registration key for one of the
  1538.            applications on the list, simply select the application and  choose
  1539.            the "Generate  Key"  option  (see page  31).  To  obtain  or  alter
  1540.            information  concerning  an  application,  such  as  the  type   of
  1541.            registration key generated or  the  generation/validation code set,
  1542.            select the application and choose the "Application Info" option. To
  1543.            remove  an  unwanted   application  from  the   list,  select   the
  1544.            application and choose  the "Delete Application"  option. When  you
  1545.            are finished with KeyGen, choose the "Close" option. Only one  copy
  1546.            of KeyGen should be running at any time.
  1547.  
  1548.            KeyGen also provides  you with  the option  of password  protecting
  1549.            applications. You can enter a password for an application when  you
  1550.            add  it   using  the   "Add  Application"   option,  or   you   can
  1551.            add/alter/remove a password  using the  "Application Info"  option.
  1552.            When a password has been entered for an application, that  password
  1553.            will be required to generate a registration key for the application
  1554.            or  to  access  or  alter   the  information  pertaining  to   that
  1555.            application.
  1556.  
  1557.            Once again, be sure  to maintain a backup  copy of your  KEYGEN.DAT
  1558.            file.
  1559.  
  1560.  
  1561.  
  1562.  
  1563.  
  1564.  
  1565.  
  1566.  
  1567.  
  1568.  -----------------------------------------------------------------------------
  1569.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 28
  1570.  
  1571.  
  1572.  CREATING GENERATION/VALIDATION CODE SETS
  1573.  -----------------------------------------------------------------------------
  1574.  
  1575.            As is introduced in "Principles of  the RegKey System" on page  23,
  1576.            for  each  application   that  uses  RegKey   you  must  create   a
  1577.            generation/validation code set. It is the uniqueness  of this  code
  1578.            set that make the  registration keys for  one of your  applications
  1579.            different from those for any other program using RegKey. The secret
  1580.            generation code is required  to generate  registration  keys  for a
  1581.            specific application. The validation code is used when checking the
  1582.            validity of the registration key at application run time.
  1583.  
  1584.            The   RegKey    API   provides    a   function / procedure    named
  1585.            RegKeyNewCodeSet(),   that    can    be   used    to    create    a
  1586.            generation/validation code set for a new application.  However, the
  1587.            quickest and easiest way  to create a  new code set  is to use  the
  1588.            KeyGen program included in your RegKey package. KeyGen also  stores
  1589.            the new code set in its data file for your future reference. If you
  1590.            would prefer to write  your own program that  generates a code  set
  1591.            using   the   RegKeyNewCodeSet()   function/procedure,   see    the
  1592.            information on calling RegKeyNewCodeSet() in the section of part  4
  1593.            that deals with the programming language you are using.
  1594.  
  1595.            The RegKey generation and validation codes are both  represented as
  1596.            ten digit strings of numbers and upper-case letters. Although it is
  1597.            mathematically possible for  the validation code  to be  calculated
  1598.            from the generation code, the reverse is not true; there is no easy
  1599.            way to calculate  the generation  code given  the validation  code.
  1600.            Therefore,  the process of creating a new code set  involves RegKey
  1601.            calculating a  validation  code from  a  generation code  that  you
  1602.            provide.
  1603.  
  1604.            To create a code set for a new application (or version),  start the
  1605.            KeyGen utility as described on page 27. Select "New Application" to
  1606.            create a new code set, in  order to bring up the "New  Application"
  1607.            dialog box. Enter the name of the application for which you will be
  1608.            generating a new code  set. This name  is not used  as part of  the
  1609.            code set  generation  process;  it is  simply  used  by  KeyGen  to
  1610.            distinguish between code sets if you generate more than one.
  1611.  
  1612.            Next,  enter  the  10  character   generation  code   for  which  a
  1613.            corresponding validation code  will be calculated.  These two codes
  1614.            will form the new  code set.  The generation code  you enter should
  1615.            consist of numbers and upper case letters,  and should be different
  1616.            for each of your applications.
  1617.  
  1618.            KeyGen gives you the option of  protecting the  new code set with a
  1619.            password. This password  can  prevent  other people who have access
  1620.            to your computer or data files from  unauthorized access to the new
  1621.            generation/validation code  set.  KeyGen  will  also  require  this
  1622.            password to  be  entered  before  a new  registration  key  can  be
  1623.  
  1624.  -----------------------------------------------------------------------------
  1625.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 29
  1626.  
  1627.  
  1628.            generated for your application. If you choose to enter a  password,
  1629.            note that it will  not appear when typed.  Be very careful to  note
  1630.            the spelling and  capitalization of  the password  you choose;  the
  1631.            password will have  to be entered  identically in  the future.  The
  1632.            best passwords are  between six  and twelve  characters in  length.
  1633.            Remember that the password  you enter has no  effect on the  actual
  1634.            validation code that is generated - it only controls access to that
  1635.            information when stored within KeyGen.
  1636.  
  1637.            The "New  Application"  dialog  box also  allows  you  to  indicate
  1638.            whether your application will  be using user-entered or  file-based
  1639.            registration keys.  Again, this  information  does not  affect  the
  1640.            actual generation/validation codes.  This setting only controls the
  1641.            type of registration key that KeyGen will create,  if you choose to
  1642.            use KeyGen to generate registration keys for your application  (see
  1643.            "Generating Registration Keys" on page 31).  For information on the
  1644.            benefits of  file-based  vs. user-entered  registration  keys,  see
  1645.            "File-Base vs. User-Entered Registration Keys" on page 25.
  1646.  
  1647.            Once you  have  entered  the relevant  information  into  the  "New
  1648.            Application" dialog box,  choose "OK" to  calculate the  validation
  1649.            code that  corresponds  to the  generation  code you  entered.  The
  1650.            generation and validation codes  will now be  stored in the  KeyGen
  1651.            data file, KEYGEN.DAT. To view the generation and validation  codes
  1652.            for a particular application, select  that application in the  main
  1653.            KeyGen window, and  choose the  "Application Info"  option. If  you
  1654.            have password  protected  the  selected  application,  KeyGen  will
  1655.            prompt  for  the  application's  password  before  displaying   any
  1656.            information about the selected application.
  1657.  
  1658.            When  you  create  a  generation/validation  code  set  for  a  new
  1659.            application, you should  always write these  codes down  in a  safe
  1660.            location. Otherwise, if the  KeyGen data file  is lost or  damaged,
  1661.            you could loose the ability to generate registration keys for  your
  1662.            own software!
  1663.  
  1664.  
  1665.  
  1666.  
  1667.  
  1668.  
  1669.  
  1670.  
  1671.  
  1672.  
  1673.  
  1674.  
  1675.  
  1676.  
  1677.  
  1678.  
  1679.  
  1680.  -----------------------------------------------------------------------------
  1681.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 30
  1682.  
  1683.  
  1684.  GENERATING REGISTRATION KEYS
  1685.  -----------------------------------------------------------------------------
  1686.  
  1687.            You will typically generate a registration key once for each  user,
  1688.            when they pay for  your software. Registration  keys may either  be
  1689.            generated using the KeyGen program included in your RegKey package,
  1690.            or they may be generated using your own utility which in turn calls
  1691.            upon RegKey to perform the actual registration key generation.  You
  1692.            will most likely  choose to  generate registration  keys using  the
  1693.            KeyGen program. However, if you wish to integrate the  registration
  1694.            key generation process  with another  program (such  as an  on-line
  1695.            registration system or an order entry system), you may perform  key
  1696.            generation by calling a RegKey API function/procedure.  For general
  1697.            information on  using the  KeyGen program,  see the  section  which
  1698.            begins  on  page  27.   For  information  on   calling  RegKey  API
  1699.            functions/procedures from your programming language, see part  four
  1700.            of this manual, which begins on page 47.
  1701.  
  1702.            If you are generating a registration key using the KeyGen  program,
  1703.            first start up KeyGen as described  in the section which begins  on
  1704.            page 27. Next select the application for which you wish to generate
  1705.            a registration key, and choose the  "Generate Key" option. The  key
  1706.            generation dialog box will now appear  on your screen. This  dialog
  1707.            box is used to provide information about the registration key to be
  1708.            generated. (If  you  have  not yet  added  information  about  your
  1709.            application to the KeyGen program, it  will not appear on the  list
  1710.            of  available   applications.   In   this   case,   see   "Creating
  1711.            Generation/Validation Code Sets" on page 29.)
  1712.  
  1713.            When generating a registration  key, you MUST  SUPPLY at least  the
  1714.            following two pieces of information:
  1715.  
  1716.           A.  The registration string, which is usually the user's name
  1717.           B.  A ten digit alphanumeric random seed
  1718.  
  1719.            Depending upon your  circumstances, the  following information  MAY
  1720.            ALSO BE REQUIRED:
  1721.  
  1722.           C.  If you are using KeyGen  to generate the registration key for a
  1723.               password protected application, this  password must be  entered
  1724.               to generate a registration key.
  1725.           D.  If you  are  writing  your own  key  generation  utility,  that
  1726.               utility must specify the generation code  for your application.
  1727.               (If you  are  using  KeyGen , it  automatically  provides  this
  1728.               information for the application you selected.)
  1729.           E.  When generating a file-base  registration key, you may  specify
  1730.               the filename to be used for the new registration key.
  1731.  
  1732.            To elaborate:
  1733.  
  1734.  
  1735.  
  1736.  -----------------------------------------------------------------------------
  1737.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 31
  1738.  
  1739.  
  1740.           A.  The registration string  is usually  the user's  name, but  may
  1741.               also contain other information, such as registration key expiry
  1742.               data. For  more information  on  the registration  string,  see
  1743.               "Principles of the RegKey System" on page 23.
  1744.  
  1745.           B.  In order to generate a registration key, RegKey requires  a ten
  1746.               character alphanumeric string which it uses as a  simple random
  1747.               number seed. If this  string includes more than  ten character,
  1748.               the additional characters are ignored. A different  random seed
  1749.               should be chosen for each registration key that is generated.
  1750.  
  1751.           C.  If you are using KeyGen  to generate the  registration key, and
  1752.               you have entered a password for the selected  application, this
  1753.               password must  be  entered. The  password  portion of  the  key
  1754.               generation dialog box is enabled if  and only if a  password is
  1755.               required for this application. Note that the password  will not
  1756.               appear on the screen when it is typed. If an incorrect password
  1757.               is entered,  KeyGen will  refuse to  generate the  registration
  1758.               key.
  1759.  
  1760.           D.  If you  are  writing  your own  key  generation  utilit y, that
  1761.               utility must specify the generation code  for your application.
  1762.               The ten digit  generation code  is passed  as a  string to  the
  1763.               registration  key  generation  function.  For   information  on
  1764.               creating a generation code, see "Creating Generation/Validation
  1765.               Code Sets" on page 29. (If you are using KeyGen to generate the
  1766.               registration key, it automatically provides the generation code
  1767.               for the application you selected.)
  1768.  
  1769.           E.  If you are  generating a file-based  registration key, you  may
  1770.               optionally specify the registration key filename to be used. If
  1771.               you do not specify a filename, RegKey will default to using the
  1772.               first eight alphabetical characters in the registration string,
  1773.               with a .KEY extension.  For instance, the default  filename for
  1774.               the registration string "Brian Pirie" would  be "BRIANPIR.KEY".
  1775.               Likewise, for  the  registration  string  "1-2-3  Clocks",  the
  1776.               default filename  would be  "CLOCKS.KEY". If  the  registration
  1777.               string  does  not  contain  any  alphabetical  characters,  the
  1778.               default filename is "REGISTER.KEY". If you explicitly specify a
  1779.               registration key filename, that filename may optionally include
  1780.               a path to the directory where the registration key  file should
  1781.               be created.  If  no  path/filename is  specified,  the  current
  1782.               directory is used by default.
  1783.  
  1784.               CAVEAT: If  a registration  key file  already  exists with  the
  1785.               specified filename, it will be overwritten by the new one.
  1786.  
  1787.            If you are using KeyGen to generate the registration key, choosing
  1788.            "OK" will cause a registration key to be generated, based upon the
  1789.            information entered.  If  the "OK"  button  of the key  generation
  1790.            dialog box  is not  enabled,  be sure  that you have  specified  a
  1791.  
  1792.  -----------------------------------------------------------------------------
  1793.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 32
  1794.  
  1795.  
  1796.            registration string, a valid 10-digit random  seed,  and a password
  1797.            if required. When  generating user-entered  registration keys,  the
  1798.            generated registration key will be  displayed in a separate  dialog
  1799.            box. You  will now  have the  option of  either generating  another
  1800.            registration key for the current  application, or returning to  the
  1801.            main KeyGen window. When generating a file-based registration  key,
  1802.            the registration key file  will be created  and another dialog  box
  1803.            will  appear  indicating  whether  or  not  you  wish  to  generate
  1804.            additional registration keys for the current application.
  1805.  
  1806.            If you  are  generating  registration keys  from  within  your  own
  1807.            program, key generation is  performed by one  of the following  two
  1808.            functions/procedures:
  1809.  
  1810.                 RegKeyGenerate()
  1811.                 RegKeyFileGenerate()
  1812.  
  1813.            The first  function/procedure  is  used  to  generate  user-entered
  1814.            registration keys, and  the second  is used  to generate  file-base
  1815.            registration keys. The registration string, generation code, random
  1816.            seed and other  information required for  key generation is  passed
  1817.            directly to  one  of these  functions/procedures.  In the  case  of
  1818.            RegKeyGenerate(), the 20 character registration key is returned  to
  1819.            your  program.  In  the  case  of  RegKeyFileGenerate(),   the  new
  1820.            registration key file is created.
  1821.  
  1822.  
  1823.  
  1824.  
  1825.  
  1826.  
  1827.  
  1828.  
  1829.  
  1830.  
  1831.  
  1832.  
  1833.  
  1834.  
  1835.  
  1836.  
  1837.  
  1838.  
  1839.  
  1840.  
  1841.  
  1842.  
  1843.  
  1844.  
  1845.  
  1846.  
  1847.  
  1848.  -----------------------------------------------------------------------------
  1849.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 33
  1850.  
  1851.  
  1852.  VALIDATING REGISTRATION KEYS WITHIN YOUR PROGRAM
  1853.  -----------------------------------------------------------------------------
  1854.  
  1855.            In order  to provide  registration key  validation capabilities,  a
  1856.            portion of RegKey is linked into the executable (.EXE, .COM,  .DLL,
  1857.            etc.) file  of your  application. The  actual process  for  linking
  1858.            RegKey with  your program  varies  depending upon  the  programming
  1859.            language you are using. For more  information on doing this with  a
  1860.            particular language, consult Part Four of this manual (which begins
  1861.            on page 47) and/or your language's manual(s).
  1862.  
  1863.            To cause the registration key validation to be performed, you  call
  1864.            one of two RegKey functions/procedures, depending upon whether  you
  1865.            are using  user-entered  or  file-based  registration  keys.  These
  1866.            functions/procedures are as follows:
  1867.  
  1868.                 RegKeyValidate()         - For user-entered registration keys
  1869.                 RegKeyFileValidate()     - For file-based registration keys
  1870.  
  1871.            The registration key validation code for your application is passed
  1872.            to  either  RegKeyValidate()  or  RegKeyFileValidate()  as   a  ten
  1873.            character alphanumeric string. If  RegKeyValidate() is being  used,
  1874.            the registration string and registration key are also passed to the
  1875.            function. In the case that RegKeyFileValidate() is being used,  the
  1876.            registration key filename and string where the registration  string
  1877.            should be stored are passed to the function/procedure. In addition,
  1878.            a variable  is  passed  to  RegKeyValidate()/  RegKeyFileValidate()
  1879.            which will be set to indicate  whether your program should  operate
  1880.            in registered or unregistered mode. Based  on how RegKey sets  this
  1881.            variable, you can adjust the behavior of your program as you  wish.
  1882.            Both of these functions  return a value  indicating whether or  not
  1883.            they executed successfully.
  1884.  
  1885.            The RegKeyValidate() function requires the following parameters, in
  1886.            order:
  1887.  
  1888.            sRegString        The registration  string to  be validated.  This
  1889.                              sting  can  consist  of  up  to   either  65,535
  1890.                              characters, or the  maximum size  of strings  in
  1891.                              your programming language, whichever is less.
  1892.  
  1893.            sRegKey           A   twenty  character   string   containing  the
  1894.                              registration key  to  be validated  against  the
  1895.                              registration string.
  1896.  
  1897.            sValidationCode   A   ten   character   string   containing   your
  1898.                              applications validation code.
  1899.  
  1900.            sYourName         A string  containing  your  name,  if  you  have
  1901.                              registered RegKey. Otherwise, this should  be an
  1902.                              empty string.
  1903.  
  1904.  -----------------------------------------------------------------------------
  1905.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 34
  1906.  
  1907.  
  1908.  
  1909.            nYourKey          A   long   integer   containing    your   RegKey
  1910.                              registration key if you have  registered RegKey.
  1911.                              Otherwise
  1912.  
  1913.            peRegistered      The variable  where the  result o f registration
  1914.                              key  validation  should  be   stored.  Indicates
  1915.                              whether the program should operate in registered
  1916.                              or unregistered mode. See  section four of  this
  1917.                              manual for the  possible values of  peRegistered
  1918.                              in your programming language.
  1919.  
  1920.            Hence, a typical call to the RegKeyValidate() function might appear
  1921.            as follows (in no particular programming language):
  1922.  
  1923.                      result = RegKeyValidate( theRegistrationString,
  1924.                                               theRegistrationKey,
  1925.                                               myValidationCode,
  1926.                                               "A RegKey Programmer",
  1927.                                               0,
  1928.                                               isRegistered)
  1929.  
  1930.  
  1931.            The   RegKeyFileValidate()   function   requires   the   following
  1932.            parameters, in order:
  1933.  
  1934.            sFileName         The  filename  or  file  specification   of  the
  1935.                              registration key file. If this string  is empty,
  1936.                              *.KEY is used. You  will likely want to  specify
  1937.                              the path to  your application's main  directory,
  1938.                              where the registration key file would usually be
  1939.                              installed by the  user. For instance,  sFileName
  1940.                              might be "C:\MYAPP\*.KEY".
  1941.  
  1942.            sValidationCode   A   ten   character   string   containing   your
  1943.                              applications validation code.
  1944.  
  1945.            sYourName         A string  containing  your  name,  if  you  have
  1946.                              registered RegKey. Otherwise, this should  be an
  1947.                              empty string.
  1948.  
  1949.            nYourKey          A   long   integer   containing    your   RegKey
  1950.                              registration key if you have  registered RegKey.
  1951.                              Otherwise
  1952.  
  1953.            sRegString        A string  where  the registration  string  (e.g.
  1954.                              user's name) retrieved from the registration key
  1955.                              file will be  stored. If  no valid  registration
  1956.                              key file  was  located,  RegKey will  return  an
  1957.                              empty string in this variable.
  1958.  
  1959.  
  1960.  -----------------------------------------------------------------------------
  1961.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 35
  1962.  
  1963.  
  1964.            cbMaxStringSize   The maximum  size  of the  registration  string,
  1965.                              expressed in the string size conventions used by
  1966.                              the host  programming  language.  In  C  or  C++
  1967.                              programs, this  should  contain  the  number  of
  1968.                              bytes allocated for  the string  and the  string
  1969.                              termination character. In Pascal, this should be
  1970.                              the number  of  characters  specified  when  the
  1971.                              string was  declared,  or  255 if  no  size  was
  1972.                              specified. In BASIC, this specifies  the maximum
  1973.                              number of characters that RegKey should retrieve
  1974.                              for the registration string. For variable-length
  1975.                              strings in  QuickBASIC, this  can be  any  value
  1976.                              between 1 and  255. For variable-length  strings
  1977.                              in Visual Basic, this can be any value between 1
  1978.                              and 30,000.
  1979.  
  1980.            peRegistered      The variable  where the  result of  registration
  1981.                              key  validation  should  be   stored.  Indicates
  1982.                              whether the program should operate in registered
  1983.                              or unregistered mode. See  section four of  this
  1984.                              manual for the  possible values of  peRegistered
  1985.                              in your programming language.
  1986.  
  1987.            Hence, a typical  call to the  RegKeyFileValidate() function might
  1988.            appear as follows (in no particular programming language):
  1989.  
  1990.                      result = RegKeyFileValidate(  "*.KEY",
  1991.                                                    myValidationCode,
  1992.                                                    "A RegKey Programmer",
  1993.                                                    0,
  1994.                                                    registrationString,
  1995.                                                    50,
  1996.                                                    isRegistered)
  1997.  
  1998.            Typically, you will  store the value  returned in the  peRegistered
  1999.            parameter in one or more global variables, that will be  accessible
  2000.            at any time your program needs  to know whether it is operating  in
  2001.            registered or unregistered  mode. There are  no limitations on  how
  2002.            you  adjust  your   program's  behavior   between  registered   and
  2003.            unregistered modes.
  2004.  
  2005.            For an example of how to perform registration key validation within
  2006.            your programming  language, see  the source  code for  the  DemoApp
  2007.            example program. The RegKey package includes equivalent source code
  2008.            of DemoApp in the C, C++, Turbo Pascal, QuickBASIC and Visual Basic
  2009.            languages.
  2010.  
  2011.            For  more   information   on  calling   the   RegKeyValidate()   or
  2012.            RegKeyFileValidate() functions,  see the  section of  part four  of
  2013.            this manual that deals with the programming language you are using.
  2014.  
  2015.  
  2016.  -----------------------------------------------------------------------------
  2017.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 36
  2018.  
  2019.  
  2020.  METHODS FOR ADDING EXPIRY INFORMATION
  2021.  -----------------------------------------------------------------------------
  2022.  
  2023.            Often, you  will want  to provide  users of  your software  with  a
  2024.            single registration key that  will work with  all versions of  your
  2025.            application. This is exactly what you achieve by simply  generating
  2026.            registration keys with the user's name as the registration  string,
  2027.            and using the same generation/ validation code set for all versions
  2028.            of your  application. However,  in some  cases  you may  only  want
  2029.            registration keys  to function  with  particular versions  of  your
  2030.            application. Alternatively, you  may wish  to limit  the length  of
  2031.            time for which the registration key  will continue to function.  In
  2032.            each of these cases, you are adding some form of expiry information
  2033.            to your registration keys.
  2034.  
  2035.            There are two basic methods for adding expiry information to RegKey
  2036.            registration keys:
  2037.  
  2038.           1.  Using different generation/validation  code set s for different
  2039.               versions of your application.
  2040.  
  2041.           2.  Including expiry information in the registration string.
  2042.  
  2043.            The first  method,  where  you are  using  different code  sets for
  2044.            different versions of your application, is only applicable when you
  2045.            wish to  generate registration  keys that  only work  with  certain
  2046.            versions of your application. If you wish to include any other form
  2047.            of expiry information in your registration keys,  you must  use the
  2048.            second  method,  where   this  information  is   imbedded  in   the
  2049.            registration string.  Below, both of these methods are described in
  2050.            detail:
  2051.  
  2052.           1.  If you  wish different  registration keys  to  be required  for
  2053.               different versions of your  applications, the easiest  approach
  2054.               is  to  use  different  generation/validation  code   sets  for
  2055.               versions that you wish to require different  registration keys.
  2056.               For instance, if you wish to require the user to pay to upgrade
  2057.               from one major  version of  your application to  the next,  you
  2058.               could use one code  set for the 1.x  version(s), a second  code
  2059.               set for the 2.x version(s), and so on. If you are  using KeyGen
  2060.               to generate registration keys, you would then end up  with both
  2061.               "MyApp  1.x"  and  "MyApp   2.x"  in  the  list   of  available
  2062.               applications. When either a  new user purchases version  2.x of
  2063.               your application, or a current user pays to upgrade  to version
  2064.               2.x, you would generate a  new registration key using  the code
  2065.               set for version 2.x.
  2066.  
  2067.               If you only wish to add simple by-version expiry information to
  2068.               your registration keys, this is probably the preferable method,
  2069.               as it does not require the expiry information to be included in
  2070.               the registration  string. This  is particularly  relevant  when
  2071.  
  2072.  -----------------------------------------------------------------------------
  2073.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 37
  2074.  
  2075.  
  2076.               using user-entered registration keys, as the user does not have
  2077.               to enter  the  expiry method  in  addition  to their  name  and
  2078.               registration key.
  2079.  
  2080.           2.  The second, more flexible option for adding  expiry information
  2081.               to your registration keys is  to imbed this information  in the
  2082.               registration string. In this case, the registration string does
  2083.               not only contain the user's name, but also includes information
  2084.               such as the version or version(s) registered or the expiry date
  2085.               of the registration key.  Since the registration key  generated
  2086.               for the  registration  string  proves its  validity,  the  user
  2087.               cannot change  the  information  included in  the  registration
  2088.               string without invalidating the registration key. When  you use
  2089.               this approach, it is important that you choose a  strict format
  2090.               for the registration key. For instance, if you wish  to include
  2091.               the user's  name and  the date  of expiry  in the  registration
  2092.               string, you might decide to format the string with  four digits
  2093.               for the year, followed by a  dash (`-') followed by  two digits
  2094.               for the month, and  so on. You might  also decide that a  comma
  2095.               and a space  will separate the  date and  user's name. In  this
  2096.               case, the registration string might appear as follows:
  2097.  
  2098.                      1997-11-28, Brian Pirie
  2099.  
  2100.               While the  method of  using different  code  set s can  be  used
  2101.               equally well  with  file-based  and  user-entered  registration
  2102.               keys, imbedding expiry  information in  the registration string
  2103.               is better suited  to file-based  registration keys. While  this
  2104.               method can also be used with user-entered registration keys, it
  2105.               does require the user to manually enter any expiry information.
  2106.               If you do  choose to  use user-entered  registration keys  with
  2107.               this method, you may wish  to provide some mechanism  to ensure
  2108.               that the  registration string  is correctly  entered into  your
  2109.               application. One approach  would be  to break the  registration
  2110.               string into a number of fields, requiring the user to enter the
  2111.               value for each field. You would then construct the registration
  2112.               string at application  run-time, and  use RegKey  to check  the
  2113.               validity of the  registration key  against this  string. As  an
  2114.               example, your program might have a registration dialog box with
  2115.               the following fields:
  2116.  
  2117.                                    Your Full Name : Brian Pirie
  2118.                       Year of Registration Expiry : 1997
  2119.                      Month of Registration Expiry : November
  2120.                        Day of Registration Expiry : 28
  2121.                                  Registration Key : KT4BP0TRX6AQ2MJK8KFU
  2122.  
  2123.               From this  information,  you  could generate  an   appropriately
  2124.               formatted registration string, such as:
  2125.  
  2126.                      1997-11-28, Brian Pirie
  2127.  
  2128.  -----------------------------------------------------------------------------
  2129.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 38
  2130.  
  2131.  
  2132.  
  2133.               If, on the  other hand, you  use file-based registration  keys,
  2134.               this difficulty is avoided, as the registration string with any
  2135.               expiry information is stored in the registration key file.
  2136.  
  2137.               Imbedding expiry information in the registration string enables
  2138.               many variations on the use of RegKey. Possibilities include:
  2139.  
  2140.                      - Selling registration keys  that work with  the current
  2141.                        and next version of your software.
  2142.  
  2143.                      - Giving the  user  the option  of  either purchasing  a
  2144.                        "life-time" registration  for  all  versions  of  your
  2145.                        application, or purchasing a  cheaper registration for
  2146.                        only the current version.
  2147.  
  2148.                      - Implementing  a  pay-by-use  system   where  the  user
  2149.                        receives a new registration key when they pay for more
  2150.                        time. In  such  a  system,  a registration  key  could
  2151.                        expire after a certain date or  after a certain number
  2152.                        of uses.
  2153.  
  2154.                      - Providing multiple  levels of  functionality depending
  2155.                        upon the level of the user's registration.
  2156.  
  2157.                      - Creating special  "beta-user"  registration keys  that
  2158.                        work for  both beta-test  and final  release versions,
  2159.                        while "normal" registration  keys work only  for final
  2160.                        release versions.
  2161.  
  2162.                      - Implementing an  on-line  "trial" registration  system
  2163.                        that  allows   the   user   to   obtain   trail-period
  2164.                        registration   keys   without   purchasing    a   full
  2165.                        registration.
  2166.  
  2167.  
  2168.  
  2169.  
  2170.  
  2171.  
  2172.  
  2173.  
  2174.  
  2175.  
  2176.  
  2177.  
  2178.  
  2179.  
  2180.  
  2181.  
  2182.  
  2183.  
  2184.  -----------------------------------------------------------------------------
  2185.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 39
  2186.  
  2187.  
  2188.  SECURITY ISSUES
  2189.  -----------------------------------------------------------------------------
  2190.  
  2191.            When using  RegKey in  any program,  it is  your responsibility  to
  2192.            decide whether employing RegKey alone provides enough  security for
  2193.            your needs. While using RegKey  alone does provide enough  security
  2194.            for the vast majority of applications, there may be times when  you
  2195.            wish to augment  or combine RegKey  with other software  protection
  2196.            mechanisms. This section provides a brief discussion of some of the
  2197.            issues you may wish to consider when using RegKey, and attempts  to
  2198.            answer the question "how secure is RegKey?"
  2199.  
  2200.            When  evaluating   any   software  protection   scheme,   such   as
  2201.            registration key mechanisms, it is important  to keep in mind  that
  2202.            no such mechanism is 100% secure. If your program can be  executed,
  2203.            it can  be reverse-engineered  and altered.  Fortunately, the  fact
  2204.            that it is possible to beat  a software protection scheme does  not
  2205.            necessarily render that  scheme as ineffective.  In general, it  is
  2206.            sufficient for  a software  protection  mechanism to  be  difficult
  2207.            enough to beat that most users will be more likely to pay for  your
  2208.            software than attempt to "beat the system". Yet as was said before,
  2209.            it is up to you  to decide how much  security you require for  your
  2210.            software.
  2211.  
  2212.            In general, there are three basic  ways in which someone might  try
  2213.            to bypass the software protection of a program that uses RegKey.
  2214.  
  2215.           1.  By always using the program in unregistered mode
  2216.           2.  By producing a "counterfeit" registration key for your program
  2217.           3.  By "hacking" or somehow  modifying your software in  order that
  2218.               it operates in registered mode without a valid registration key
  2219.               being present.
  2220.  
  2221.            Each of these possibilities are discussed below:
  2222.  
  2223.           1.  By far the most common  way that users bypass  registration key
  2224.               systems is by  always using  the program  in unregistered  mode
  2225.               without paying for it. The likelihood of users doing  this with
  2226.               your software depends largely upon the type of  application and
  2227.               the incentives you  offer for registering.  In some cases,  the
  2228.               majority  of  people  using   a  software  package  that   uses
  2229.               registration keys  will be  using  it without  registering.  In
  2230.               other cases, almost everyone using the software will  have paid
  2231.               to register it.
  2232.  
  2233.               There are a number of things that you can do to encourage users
  2234.               to pay for your software  rather than using it  in unregistered
  2235.               mode:
  2236.  
  2237.               -  If the output of  your software will be  seen by many people
  2238.                  in addition to the  user who is  responsible for registering
  2239.  
  2240.  -----------------------------------------------------------------------------
  2241.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 40
  2242.  
  2243.  
  2244.                  it (such as communications  software, on-line bulletin board
  2245.                  software, programming library or other program that produces
  2246.                  unalterable  output),  then  displaying   or  outputting  an
  2247.                  "unregistered" message can be  sufficient to encourage users
  2248.                  to pay  for your  software. In  this case,  the unregistered
  2249.                  message has the potential  to advertise to  many people that
  2250.                  it is an evaluation copy and must be paid for.
  2251.  
  2252.               -  A common  and  effective  incentive  to  encourage users  to
  2253.                  register software is the enabling of additional capabilities
  2254.                  when  operating   in  registered   mode.   These  additional
  2255.                  capabilities could be the additional helpful features for an
  2256.                  application, additional  "levels" of  a video  game,  or the
  2257.                  removal  of  demonstration-version  limitations  such  as  a
  2258.                  maximum data file size. If you  are taking this approach, be
  2259.                  careful not  to  cripple  your  software's  capabilities  in
  2260.                  unregistered  mode  too   severely.  If  the   user  becomes
  2261.                  frustrated with  your software,  it is  unlikely   that they
  2262.                  will want to pay for it. Likewise, you  will want to be sure
  2263.                  that the  user has  an opportunity  to  examine all  of your
  2264.                  software's important capabilities.
  2265.  
  2266.               -  Another common incentive is to  offer additional services to
  2267.                  registered users,  such  as  printed documentation,  product
  2268.                  support, free upgrade to new versions, source code, etc.
  2269.  
  2270.               -  Another possible approach is to have your software only work
  2271.                  for a certain period of time without registering. To make it
  2272.                  more  difficult  for   users  to   bypass  this   scheme  by
  2273.                  reinstalling  the   software,  you   might  want   to  store
  2274.                  information  about   the  date   and  time   of   the  first
  2275.                  installation in your program's data file (if applicable).
  2276.  
  2277.               -  An alternative to causing  the software itself  to expire is
  2278.                  to require the user  to obtain a  temporary "evaluation" key
  2279.                  from you  to even  operate  in unregistered  mode.  This key
  2280.                  could expire after any  length of time you  choose. For more
  2281.                  information on  adding  expiry information  to  registration
  2282.                  keys, see the section that begins on page 37.
  2283.  
  2284.  
  2285.           2.  A second way  a user  might try  to bypass  a RegKey  protected
  2286.               application is by  producing a  "counterfeit" registration  key
  2287.               for your  software.  However, RegKey  is  designed to  make  it
  2288.               extremely difficult to do this. There are two  conceivable ways
  2289.               someone might try to generate a counterfeit RegKey registration
  2290.               key:
  2291.  
  2292.               A  by an exhaustive search of all possible registration keys
  2293.               B  by determining your application's  generation code and using
  2294.                  RegKey's KeyGen program to produce a registration key.
  2295.  
  2296.  -----------------------------------------------------------------------------
  2297.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 41
  2298.  
  2299.  
  2300.  
  2301.               An exhaustive  search  would not  be  feasible, even  with  the
  2302.               world's fastest supercomputer. There  are nearly 2^96  possible
  2303.               RegKey registration keys, of which nearly 2^48 are valid  for a
  2304.               given registration string. This means that on average, 2^47  (1
  2305.               followed by 14 zeros) registration keys must be tried  before a
  2306.               valid registration key is  found. To put  this into context,  a
  2307.               fully optimized version of the RegKeyValidate () function would
  2308.               require over more than 1 millisecond to determine  the validity
  2309.               of a RegKey registration key on a 66-Mhz Pentium based machine.
  2310.               Even being able to test 1000 registration keys per second, such
  2311.               a machine  would require  over 4,400  years to  guess a  RegKey
  2312.               registration key on average.
  2313.  
  2314.               Determining  the  generation  code   for  your  application  by
  2315.               guessing would  be  just as  difficult  as guessing  a  correct
  2316.               registration key. Also, although  a RegKey validation code  can
  2317.               be quickly calculated from the generation code, the  reverse is
  2318.               not the case. There is no known mathematical method  that would
  2319.               allow you to  quickly determine the  generation code given  the
  2320.               validation code. As  a result,  even if  the user  was able  to
  2321.               obtain the validation code  from your application's  executable
  2322.               file(s), they  would be  no closer  to  knowing the  generation
  2323.               code.
  2324.  
  2325.  
  2326.           3.  A third way someone might try to defeat a program  using RegKey
  2327.               is by  someone modifying  the program  to  cause it  to  always
  2328.               operate in registered  mode. The vast  majority of users  would
  2329.               not have the ability to do  this. However, there is  always the
  2330.               fear that someone  with the ability  to do  so may "hack"  your
  2331.               program and even distribute an altered version to  other users.
  2332.               While it  is  very  seldom  that  this  scenario  causes  major
  2333.               problems in  reality,  you may  still  wish  to take  steps  to
  2334.               further protect your program from "hacking".
  2335.  
  2336.               In any program using RegKey,  the weakest link is  generally at
  2337.               the point  where  the  program passes  control  to  the  RegKey
  2338.               routines. As  a result  you may  want to  somehow encrypt  (see
  2339.               glossary) or check  the validity of  this code  at run time.  A
  2340.               full discussion of such techniques is beyond the scope  of this
  2341.               manual. If you  wish to  add further robustness  to the  RegKey
  2342.               code itself, you  may wish  to obtain the  source code  package
  2343.               (see page 13) to make such modifications.
  2344.  
  2345.               If you are using RegKey with  Visual Basic or Turbo  Pascal for
  2346.               Windows, you  should  consider  checking the  validity  of  the
  2347.               RegKey DLL at run time. For instance, your program could locate
  2348.               the  RK31VB.DLL  or  RK31TP.DLL  file  (depending   upon  which
  2349.               language you are  using) and  calculate a  checksum, CRC-32  or
  2350.               other hash  value  for  the  file. That  value  could  then  be
  2351.  
  2352.  -----------------------------------------------------------------------------
  2353.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 42
  2354.  
  2355.  
  2356.               compared with an  expected value to  determine whether the  DLL
  2357.               has been altered.
  2358.  
  2359.  
  2360.  
  2361.  
  2362.  
  2363.  
  2364.  
  2365.  
  2366.  
  2367.  
  2368.  
  2369.  
  2370.  
  2371.  
  2372.  
  2373.  
  2374.  
  2375.  
  2376.  
  2377.  
  2378.  
  2379.  
  2380.  
  2381.  
  2382.  
  2383.  
  2384.  
  2385.  
  2386.  
  2387.  
  2388.  
  2389.  
  2390.  
  2391.  
  2392.  
  2393.  
  2394.  
  2395.  
  2396.  
  2397.  
  2398.  
  2399.  
  2400.  
  2401.  
  2402.  
  2403.  
  2404.  
  2405.  
  2406.  
  2407.  
  2408.  -----------------------------------------------------------------------------
  2409.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 43
  2410.  
  2411.  
  2412.  TROUBLESHOOTING GUIDE
  2413.  -----------------------------------------------------------------------------
  2414.  
  2415.            This section provides a guide to solving common problems when using
  2416.            the RegKey system. If the suggestions  in this section do not  help
  2417.            in solving your problem, please feel more than free to get in touch
  2418.            with me. For information on how to reach me, see page 71.
  2419.  
  2420.  
  2421.            PROBLEM
  2422.            KeyGenW complains that CTL3DV2.DLL is not installed
  2423.  
  2424.            POSSIBLE SOLUTION
  2425.            The CTL3DV2.DLL file,  included in  your RegKey  package,  must  be
  2426.            placed    in    the    Windows    system    directory    (typically
  2427.            C:\WINDOWS\SYSTEM). Ensure that this file  DOES NOT also reside  in
  2428.            the current default directory,  or the directory where  KEYGENW.EXE
  2429.            is located.
  2430.  
  2431.  
  2432.  
  2433.            PROBLEM
  2434.            KeyGenW does not list applications that have been previously added
  2435.  
  2436.            POSSIBLE SOLUTION
  2437.            Ensure that the  current default directory  is the same  as it  was
  2438.            when KeyGenW was originally run, in order that the same  KEYGEN.DAT
  2439.            file can be located.
  2440.  
  2441.  
  2442.  
  2443.            PROBLEM
  2444.            Program using RegKey does not recognize a valid registration key
  2445.  
  2446.            POSSIBLE SOLUTIONS
  2447.            Check  that  the  program  is   using  the  validation  code   that
  2448.            corresponds to the generation code used to create the  registration
  2449.            key. Also  check  that the  peRegistered  parameter passed  to  the
  2450.            RegKeyValidate()  or   RegKeyFileValidate()   function   is   being
  2451.            correctly tested in your  program. If file-based registration  keys
  2452.            are being used, ensure that the registration key file is placed  in
  2453.            the current default directory  (depending upon your  circumstances,
  2454.            this may  be the  directory from  which  you started  Windows,  the
  2455.            directory  from  which   you  started  the   application  or   your
  2456.            programming language, or the directory where the application's .EXE
  2457.            file is located. If you are  unsure as to what the current  default
  2458.            directory is, explicitly pass the location of the registration  key
  2459.            file to RegKeyFileValidate(). (i.e., "C:\MYAPP\*.KEY"). Also ensure
  2460.            that only one file with a .KEY extension exists in this directory.
  2461.  
  2462.  
  2463.  
  2464.  -----------------------------------------------------------------------------
  2465.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 44
  2466.  
  2467.  
  2468.  
  2469.            PROBLEM
  2470.            C or C++ program using RegKey will not compile
  2471.  
  2472.            POSSIBLE SOLUTIONS
  2473.            If you receive unexplained errors during the compile phase,  ensure
  2474.            that the REGKEY.H  file is  "#include"ed in  your program's  source
  2475.            file, and ensure  that the correct  format for  calling the  RegKey
  2476.            functions is being used. If  you receive unexplained errors  during
  2477.            the linking phase, ensure that you are linking with the appropriate
  2478.            RegKey library file for the target environment (DOS or Windows) and
  2479.            memory model that you are using.  If you are experiencing  problems
  2480.            linking in small, compact or medium memory models, and suspect that
  2481.            the code or data segments may  be exceeding 64K in size, try  using
  2482.            the large memory model.
  2483.  
  2484.  
  2485.            PROBLEM
  2486.            QuickBASIC program using RegKey will not execute
  2487.  
  2488.            POSSIBLE SOLUTIONS
  2489.            Ensure that the  RegKey Quick Library,  REGKEYQB.QLB is located  in
  2490.            the current  directory and  that QuickBASIC has  loaded this  file
  2491.            (specify /LREGKEYQB.QLB on the QB  command line). Also ensure  that
  2492.            the REGKEY.BI  file is  included  using the  $INCLUDE  metacommand.
  2493.            Check that you are using the correct syntax for calling the  RegKey
  2494.            functions.
  2495.  
  2496.  
  2497.  
  2498.            PROBLEM
  2499.            QuickBASIC program using RegKey will not compile to .EXE file
  2500.  
  2501.            POSSIBLE SOLUTIONS
  2502.            Ensure that the RegKey stand-alone library, REGKEYQB.LIB is located
  2503.            in the correct directory and that QuickBASIC is  configured to link
  2504.            your program with  this library (specify  /LREGKEYQB.QLB on the  QB
  2505.            command line).
  2506.  
  2507.  
  2508.  
  2509.            PROBLEM
  2510.            Turbo Pascal program using RegKey will not compile or execute
  2511.  
  2512.            POSSIBLE SOLUTIONS
  2513.            Ensure that you have built the  .TPU unit for the version of  Turbo
  2514.            Pascal you are using,  and named this file  RegKeyD.TPU for DOS  or
  2515.            RegKeyW.TPU for Windows.  Also ensure that  your program refers  to
  2516.            the RegKeyD / RegKeyW  unit in the uses  statement. Check that  you
  2517.            are using the correct format for calling a RegKey function. If  you
  2518.  
  2519.  
  2520.  -----------------------------------------------------------------------------
  2521.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 45
  2522.  
  2523.  
  2524.            are using  RegKey  in  a Windows  program,  also  ensure  that  the
  2525.            RK31TP.DLL file is installed in the Windows system directory.
  2526.  
  2527.  
  2528.  
  2529.            PROBLEM
  2530.            Visual Basic program using RegKey will not run
  2531.  
  2532.            POSSIBLE SOLUTIONS
  2533.            Ensure that the RK31VB.DLL file is installed in the Windows  system
  2534.            directory. Also ensure that the REGKEYVB.BAS module is included  in
  2535.            the Visual Basic project window  for your program.  Also check that
  2536.            you are using the correct format  for calling the RegKey functions.
  2537.  
  2538.  
  2539.  
  2540.  
  2541.  
  2542.  
  2543.  
  2544.  
  2545.  
  2546.  
  2547.  
  2548.  
  2549.  
  2550.  
  2551.  
  2552.  
  2553.  
  2554.  
  2555.  
  2556.  
  2557.  
  2558.  
  2559.  
  2560.  
  2561.  
  2562.  
  2563.  
  2564.  
  2565.  
  2566.  
  2567.  
  2568.  
  2569.  
  2570.  
  2571.  
  2572.  
  2573.  
  2574.  
  2575.  
  2576.  -----------------------------------------------------------------------------
  2577.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 46
  2578.  
  2579.  
  2580.  -----------------------------------------------------------------------------
  2581.  PART 4: LANGUAGE-SPECIFIC INFORMATION
  2582.  -----------------------------------------------------------------------------
  2583.  
  2584.  
  2585.  
  2586.            This portion of the RegKey manual  describes how to use the  RegKey
  2587.            system with various programming languages, and is divided into  the
  2588.            following sections:
  2589.  
  2590.                 Using RegKey with C or C++..................................47
  2591.                 Using RegKey with QuickBASIC................................56
  2592.                 Using RegKey with Visual Basic..............................62
  2593.                 Using RegKey with Turbo Pascal..............................63
  2594.                 Using RegKey with Other Languages or Operating Systems......70
  2595.  
  2596.            Since these  sections  build on  the  language-neutral  information
  2597.            presented in Part 3 of this manual, you should read Part 3 and have
  2598.            an understanding  of the  principles of  the RegKey  system  before
  2599.            proceeding to these sections. (Part 3 begins on page 18.)
  2600.  
  2601.  
  2602.  
  2603.  USING THE REGKEY SYSTEM WITH C OR C++
  2604.  -----------------------------------------------------------------------------
  2605.  
  2606.            This section describes  how to use  the RegKey  system in  programs
  2607.            written with C or C++. Specific  information is provided for  using
  2608.            RegKey with C and  C++ compilers from  Microsoft, Borland, and  Mix
  2609.            Software including Borland Turbo C, Borland Turbo C++, Borland C++,
  2610.            Microsoft C, Microsoft Quick  C, Microsoft C/C++, Microsoft  Visual
  2611.            C++ and  Mix  Software's  Power  C.  General  information  is  also
  2612.            provided for  using  RegKey with  other  C or  C++  compilers.  The
  2613.            information provided here  is pertinent to  DOS, Windows and  other
  2614.            operating systems.
  2615.  
  2616.            In order to  use the  C/C++ version of  RegKey, you  must have  the
  2617.            RegKey package  RKEY31C.ZIP.  If you  have  the version  of  RegKey
  2618.            designed for a different programming  language, you may obtain  the
  2619.            C/C++ version of RegKey directly from me. For information on how to
  2620.            get in touch with me, please see page  71. For a list of the  files
  2621.            included in the  version of RegKey  for each programming  language,
  2622.            please see the section which begins on page 73.
  2623.  
  2624.            If you are using  a language or compiler  that is not  specifically
  2625.            discussed in this manual, the information in this section may  also
  2626.            be of  use  to you.  The  manuals included  with  many  programming
  2627.            languages provide information on how to call C language  functions.
  2628.            In these  cases, you  will need  to  know the  specifics of  the  C
  2629.            language function prototypes which are described in this section.
  2630.  
  2631.  
  2632.  -----------------------------------------------------------------------------
  2633.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 47
  2634.  
  2635.  
  2636.            In order to call the RegKey functions from a C or C++ program,  you
  2637.            must:
  2638.  
  2639.           1.  Include the  RegKey  header  file  at  the  beginning  of  your
  2640.               program's source code file(s), using the #include statement:
  2641.  
  2642.                      #include "regkey.h"
  2643.  
  2644.               Ensuring  that  the  REGKEY.H  file  is  located  in  the  same
  2645.               directory as  your program's  source code.  Alternatively,  you
  2646.               could place the  REGKEY.H file  in the same  directory as  your
  2647.               compiler's  standard  header  files.  In  this  case,   most  C
  2648.               compilers will require  you to use  angled brackets instead  of
  2649.               double quotes in the #include statement, as follows:
  2650.  
  2651.                      #include <regkey.h>
  2652.  
  2653.           2.  Link with the appropriate RegKey library file for  the platform
  2654.               (DOS or Windows) and memory  model you are using.  The included
  2655.               library files are as follows:
  2656.  
  2657.                      REGKEYSD.LIB        DOS, tiny and small memory models
  2658.                      REGKEYCD.LIB        DOS, compact memory model
  2659.                      REGKEYMD.LIB        DOS, medium memory model
  2660.                      REGKEYLD.LIB        DOS, large and huge memory models
  2661.                      REGKEYSD.LIB        Windows, small memory model
  2662.                      REGKEYCD.LIB        Windows, compact memory model
  2663.                      REGKEYMD.LIB        Windows, medium memory model
  2664.                      REGKEYLD.LIB        Windows, large and huge memory models
  2665.                      REGKEYSP.MIX        Power C, small memory model
  2666.                      REGKEYMP.MIX        Power C, medium memory model
  2667.                      REGKEYLP.MIX        Power C, large memory model
  2668.  
  2669.               The actual method  for configuring  your C or  C++ compiler  to
  2670.               link with  an additional  library varies  depending upon  which
  2671.               compiler you  are using.  You  should consult  your  compiler's
  2672.               manual for detailed information on how to do this.
  2673.  
  2674.               If you are using the Borland  Turbo C IDE, you should  create a
  2675.               text file with  a .PRJ  extension, and  list the  name of  your
  2676.               program's .C source file(s) along  with the name of  the RegKey
  2677.               library to use in the .PRJ file.
  2678.  
  2679.               If you are using the Borland Turbo C++ or Borland C++  IDE, you
  2680.               should create  a  project  file  using  the  Project|Open  menu
  2681.               option, again adding the name of your program's  source file(s)
  2682.               along with the name of the RegKey library to use.
  2683.  
  2684.               If you are using the Microsoft Quick C IDE, you should  use the
  2685.               Make|Set Program List and  Make|Edit Program List menu  options
  2686.  
  2687.  
  2688.  -----------------------------------------------------------------------------
  2689.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 48
  2690.  
  2691.  
  2692.               to include  both  your  program's .C  source  file(s)  and  the
  2693.               appropriate library files.
  2694.  
  2695.               If you  are using  Microsoft the  Visual  C++ IDE,  you  should
  2696.               choose Project|Edit to add  the name of  the RegKey library  to
  2697.               your project.
  2698.  
  2699.               If you  are using  any of  these C  or C++  compilers from  the
  2700.               command line, you must specify the appropriate  link parameters
  2701.               to cause your program to be linked with a RegKey library.
  2702.  
  2703.               If you  are using  Mix Software's  Power  C compiler,  you  can
  2704.               create a  .PRJ  project  file  that  lists  the  name  of  your
  2705.               program's .C source code file(s), along with the RegKey library
  2706.               that corresponds to the memory model  you are using. If  you do
  2707.               not specify a  memory model on  the command  line, the Power  C
  2708.               compiler uses the  medium memory  model. The  /ms command  line
  2709.               switch forces Power C  to use the small  memory model, and  /ml
  2710.               forces Power C to use the  large memory model. To  compile with
  2711.               the .PRJ project file, simply  include the name of  the project
  2712.               file on the Power C command line, instead of using the  name of
  2713.               your program's .C source code file(s).
  2714.  
  2715.            The following  example C  / C++  programs  included in  the  RegKey
  2716.            package illustrate how you can call  a RegKey function from  within
  2717.            your program:
  2718.  
  2719.                 DEMOAPPD.C     DOS C version of DemoApp
  2720.                 DEMOAPPW.C     Windows C version of DemoApp
  2721.                 DEMOAPPD.CPP   DOS object-oriented C++ version of DemoApp
  2722.                 DEMOAPPW.CPP   Windows object-oriented C++ version of DemoApp
  2723.  
  2724.            When calling either of  the registration key validation  functions,
  2725.            RegKeyValidate() or RegKeyFileValidate(), the result is returned in
  2726.            an enum of type RKVALID. To  declare a variable to hold the  result
  2727.            of registration key validation, you would use something similar  to
  2728.            the follows:
  2729.  
  2730.                 RKVALID registeredMode;
  2731.  
  2732.            The address  of this  variable is  passed to  the registration  key
  2733.            validation function using the C or C++ address-of operator (&),  as
  2734.            follows:
  2735.  
  2736.                 RegKeyValidate(szRegString, szRegKey, "KIXE4UB52K", "", 0,
  2737.                                ®isteredMode);
  2738.  
  2739.            This variable  can  have  one of  two  values,  RK_UNREGISTERED  or
  2740.            RK_REGISTERED. Therefore, at  any point in  your program where  you
  2741.            wish to  test whether  the program  is operating  in registered  or
  2742.  
  2743.  
  2744.  -----------------------------------------------------------------------------
  2745.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 49
  2746.  
  2747.  
  2748.            unregistered mode, you might include an if statement similar to the
  2749.            following:
  2750.  
  2751.                 if(registeredMode == RK_REGISTERED)
  2752.                    {
  2753.                    printf("Registered mode\n");
  2754.                    }
  2755.                 else
  2756.                    {
  2757.                    printf("Unregistered mode\n");
  2758.                    }
  2759.  
  2760.            Below, the calling format for each  of the RegKey API functions  is
  2761.            documented from  the  perspective  of the  C  and  C++  programming
  2762.            languages:
  2763.  
  2764.  
  2765.  
  2766.  
  2767.  
  2768.  
  2769.  
  2770.  
  2771.  
  2772.  
  2773.  
  2774.  
  2775.  
  2776.  
  2777.  
  2778.  
  2779.  
  2780.  
  2781.  
  2782.  
  2783.  
  2784.  
  2785.  
  2786.  
  2787.  
  2788.  
  2789.  
  2790.  
  2791.  
  2792.  
  2793.  
  2794.  
  2795.  
  2796.  
  2797.  
  2798.  
  2799.  
  2800.  -----------------------------------------------------------------------------
  2801.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 50
  2802.  
  2803.  
  2804.  -----------------------------------------------------------------------------
  2805.  LANGUAGE  C and C++
  2806.  
  2807.  FUNCTION  RegKeyNewCodeSet()
  2808.  
  2809.  PURPOSE   Creates a new generation / validation code set
  2810.  
  2811.  FORMAT    RKRETURN RegKeyNewCodeSet(
  2812.                 const char FAR *szGenerationCode,
  2813.                 char FAR *szValidationCode);
  2814.  
  2815.  RETURNS   Type RKRETURN. RK_SUCCESS on success, RK_FAILURE on failure.
  2816.  
  2817.  PARAMS    szGenerationCode    - INPUT: 10-digit generation code string
  2818.            szValidationCode    - OUTPUT: 10-digit validation code string
  2819.  
  2820.  NOTES     Generates a  registration  key  validation code corresponding  to a
  2821.            generation code.  This set  of generation  and validation  codes is
  2822.            unique for each application using RegKey, and determines the unique
  2823.            registration key that corresponds to a particular user's name.  The
  2824.            secret generation code is used at registration key generation time,
  2825.            and  the  corresponding  validation   code  is  used  within   your
  2826.            application when validating a registration key. The validation  and
  2827.            generation codes are  each represented  as a  ten-digit strings  of
  2828.            numbers and  upper-case letters.  Hence both  parameters should  be
  2829.            declared as arrays of characters of  at least 11 elements in  size.
  2830.            This function is called by KeyGen or your own utility,  and is only
  2831.            used once for each application using RegKey.
  2832.  
  2833.            The concepts of  code set creation are  introduced in  the section
  2834.            which begins on page 29.
  2835.  
  2836.  
  2837.  
  2838.  
  2839.  
  2840.  
  2841.  
  2842.  
  2843.  
  2844.  
  2845.  
  2846.  
  2847.  
  2848.  
  2849.  
  2850.  
  2851.  
  2852.  
  2853.  
  2854.  
  2855.  
  2856.  -----------------------------------------------------------------------------
  2857.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 51
  2858.  
  2859.  
  2860.  -----------------------------------------------------------------------------
  2861.  LANGUAGE  C and C++
  2862.  
  2863.  FUNCTION  RegKeyGenerate()
  2864.  
  2865.  PURPOSE   Creates a user-entered type registration key
  2866.  
  2867.  FORMAT    RKRETURN RegKeyGenerate(
  2868.                 const char FAR *szRegString,
  2869.                 const char FAR *szGenerationCode,
  2870.                 const char FAR *szRandomSeed,
  2871.                 char FAR *szRegKey);
  2872.  
  2873.  RETURNS   Type RKRETURN. RK_SUCCESS on success, RK_FAILURE on failure.
  2874.  
  2875.  PARAMS    szRegString         - INPUT: Registration string
  2876.            szGenerationCode    - INPUT: Application's generation code string
  2877.            szRandomSeed        - INPUT: Random number seed string
  2878.            szRegKey            - OUTPUT: 20-digit registration key string
  2879.  
  2880.  NOTES     Generates a  registration  key for  a  particular user,  using  the
  2881.            secret generation code  corresponding to  a particular  application
  2882.            (as passed  to  RegKeyNewCodeSet()).  The  registration  string  is
  2883.            usually the name of the registered user, but may also contain other
  2884.            information, such as the version registered or date of expiry.  The
  2885.            registration string may be zero to 64K characters in length, and is
  2886.            null-terminated. The registration  key is returned  as a string  of
  2887.            letters and upper-case letters. The  string pointed to by  szRegKey
  2888.            must be large enough  to hold 20 digits,  plus a string  terminator
  2889.            character. szRandomSeed should contain 10 random numbers and upper-
  2890.            case numbers,  which  are  required  during  the  registration  key
  2891.            generation process.
  2892.  
  2893.            This function  is called  by KeyGen or  your own  registration  key
  2894.            generation utility, each time a registration key is generated for a
  2895.            new user. This function is used for user-entered registration keys;
  2896.            compare with RegKeyFileGenerate().
  2897.  
  2898.            Concepts of  registration  key  generation are  introduced in  the
  2899.            section which begins on page 31.
  2900.  
  2901.  
  2902.  
  2903.  
  2904.  
  2905.  
  2906.  
  2907.  
  2908.  
  2909.  
  2910.  
  2911.  
  2912.  -----------------------------------------------------------------------------
  2913.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 52
  2914.  
  2915.  
  2916.  -----------------------------------------------------------------------------
  2917.  LANGUAGE  C and C++
  2918.  
  2919.  FUNCTION  RegKeyValidate()
  2920.  
  2921.  PURPOSE   Checks the validity of a user-entered registration key
  2922.  
  2923.  FORMAT    RKRETURN RegKeyValidate(
  2924.                 const char FAR *szRegString,
  2925.                 const char FAR *szRegKey,
  2926.                 const char FAR *szValidationCode,
  2927.                 const char FAR *szYourName,
  2928.                 unsigned long int nYourKey,
  2929.                 RKVALID FAR *peRegistered);
  2930.  
  2931.  RETURNS   Type RKRETURN. RK_SUCCESS on success, RK_FAILURE on failure.
  2932.  
  2933.  PARAMS    szRegString         - INPUT: Registration string
  2934.            szRegKey            - INPUT: 20-digit registration key string
  2935.            szValidationCode    - INPUT: Application's validation code string
  2936.            szYourName          - INPUT: Your name (if registered)
  2937.            nYourKey            - INPUT: Your key (if registered)
  2938.            peRegistered        - OUTPUT: Is key valid
  2939.  
  2940.  NOTES     Checks whether  a given  registration string and  registration  key
  2941.            combination is  valid  for  a  particular  application,  using  the
  2942.            application-specific  validation   code  that   was  generated   by
  2943.            RegKeyNewCodeSet(). The RKVALID pointed  to by peRegistered is  set
  2944.            to either RK_REGISTERED or  RK_UNREGISTERED, indicating whether  or
  2945.            not the registration key and registration string are valid. If  you
  2946.            have registered RegKey, your own  name and RegKey registration  key
  2947.            should  be  passed   to  this  function   to  disable  the   RegKey
  2948.            "unregistered" message.
  2949.  
  2950.            This function is called from within  your application each time  it
  2951.            executes, in  order  to  determine whether  it  should  operate  in
  2952.            registered or unregistered mode. This  function is used with  user-
  2953.            entered registration keys; compare with RegKeyFileValidate().
  2954.  
  2955.            Concepts of  registration  key  validation are  introduced  in  the
  2956.            section which begins on page 34.
  2957.  
  2958.  
  2959.  
  2960.  
  2961.  
  2962.  
  2963.  
  2964.  
  2965.  
  2966.  
  2967.  
  2968.  -----------------------------------------------------------------------------
  2969.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 53
  2970.  
  2971.  
  2972.  -----------------------------------------------------------------------------
  2973.  LANGUAGE  C and C++
  2974.  
  2975.  FUNCTION  RegKeyFileGenerate()
  2976.  
  2977.  PURPOSE   Generates a file-based registration key
  2978.  
  2979.  FORMAT    RKRETURN RegKeyFileGenerate(
  2980.                 const char FAR *szRegString,
  2981.                 const char FAR *szGenerationCode,
  2982.                 const char FAR *szRandomSeed,
  2983.                 const char FAR *szFileName);
  2984.  
  2985.  RETURNS   Type RKRETURN. RK_SUCCESS on success, RK_FAILURE on failure.
  2986.  
  2987.  PARAMS    szRegString         - INPUT: Registration string
  2988.            szGenerationCode    - INPUT: Application's generation code string
  2989.            szRandomSeed        - INPUT: Random number seed string
  2990.            szFileName          - INPUT: Registration key file name
  2991.  
  2992.  NOTES     Generates a  file-based registration  key  for a  particular  user,
  2993.            using the  secret  generation code  corresponding  to  a particular
  2994.            application (as  passed  to RegKeyNewCodeSet()).  The  registration
  2995.            string is usually  the name of  the registered user,  but may  also
  2996.            contain other information, such as  the version registered or  date
  2997.            of expiry. The registration string may be zero to 64K characters in
  2998.            length,  and  is  null-terminated.  A  registration  key  file   is
  2999.            generated,   using   the   specified   filename,   containing   the
  3000.            registration string and the resulting  registration key. If a  file
  3001.            with  the  specified  name  already  exists,  it  is   overwritten.
  3002.            szRandomSeed  should  contain  10  random  numbers  and  upper-case
  3003.            letters, which are required during the registration key  generation
  3004.            process.
  3005.  
  3006.            This function  is called  by KeyGen or  your own  registration  key
  3007.            generation utility, each time a registration key is generated for a
  3008.            new user. This function is  used for file-based registration  keys;
  3009.            compare with RegKeyGenerate().
  3010.  
  3011.            Concepts of  registration  key  generation are  introduced  in  the
  3012.            section which begins on page 31.
  3013.  
  3014.  
  3015.  
  3016.  
  3017.  
  3018.  
  3019.  
  3020.  
  3021.  
  3022.  
  3023.  
  3024.  -----------------------------------------------------------------------------
  3025.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 54
  3026.  
  3027.  
  3028.  -----------------------------------------------------------------------------
  3029.  LANGUAGE  C and C++
  3030.  
  3031.  FUNCTION  RegKeyFileValidate()
  3032.  
  3033.  PURPOSE   Checks the validity of a file-based registration key
  3034.  
  3035.  FORMAT    RKRETURN RegKeyFileValidate(
  3036.                 const char FAR *szFileName,
  3037.                 const char FAR *szValidationCode,
  3038.                 const char FAR *szYourName,
  3039.                 unsigned long int nYourKey,
  3040.                 char FAR *szRegString,
  3041.                 unsigned short int cbMaxStringSize,
  3042.                 RKVALID FAR *peRegistered);
  3043.  
  3044.  RETURNS   Type RKRETURN. RK_SUCCESS on success, RK_FAILURE on failure.
  3045.  
  3046.  PARAMS    szFileName          - INPUT: Registration key file name
  3047.            szValidationCode    - INPUT: App's validation code
  3048.            szYourName          - INPUT: Your name (if registered)
  3049.            nYourKey            - INPUT: Your key (if registered)
  3050.            szRegString         - OUTPUT: Registration string
  3051.            cbMaxStringSize     - INPUT: Size of reg. string
  3052.            peRegistered        - OUTPUT: Is key valid
  3053.  
  3054.  NOTES     Checks whether the specified registration key  file is valid for  a
  3055.            particular application, using the application-specified  validation
  3056.            code that was generated by RegKeyNewCodeSet().  The RKVALID pointed
  3057.            to  by   peRegistered   is   set   to   either   RK_REGISTERED   or
  3058.            RK_UNREGISTERED, indicating whether or not the registration key and
  3059.            registration string stored in the registration key  file are valid.
  3060.            The  szFileName  parameter  may  include  wildcards.  If  you  have
  3061.            registered RegKey, your own name and RegKey registration key should
  3062.            be passed to  this function  to disable  the RegKey  "unregistered"
  3063.            message.
  3064.  
  3065.            This function is called from within  your application each time  it
  3066.            executes, in  order  to  determine whether  it  should  operate  in
  3067.            registered or unregistered mode. This  function is used with  file-
  3068.            based registration keys; compare with RegKeyValidate().
  3069.  
  3070.            Concepts of  registration  key  validation are  introduced  in  the
  3071.            section which begins on page 34.
  3072.  
  3073.  
  3074.  
  3075.  
  3076.  
  3077.  
  3078.  
  3079.  
  3080.  -----------------------------------------------------------------------------
  3081.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 55
  3082.  
  3083.  
  3084.  USING THE REGKEY SYSTEM WITH QUICKBASIC
  3085.  -----------------------------------------------------------------------------
  3086.  
  3087.            This section describes how to use RegKey with programs written with
  3088.            the Microsoft  QuickBASIC programming  language.  RegKey  has  been
  3089.            tested with Microsoft QuickBASIC  version 4.5. Although no  testing
  3090.            has been done  with other versions,  this information would  likely
  3091.            also apply to  earlier versions  of QuickBASIC.  In addition,  this
  3092.            information may be applicable to using RegKey with Microsoft Visual
  3093.            Basic for  DOS. However,  RegKey has  not been  tested with  Visual
  3094.            Basic for DOS. For  information on using  RegKey with Visual  Basic
  3095.            for Windows, see page 62.
  3096.  
  3097.            In order to use the QuickBASIC version of RegKey, you must have the
  3098.            RegKey package  RKEY31QB.ZIP. If  you have  the version  of  RegKey
  3099.            designed for a different programming  language, you may obtain  the
  3100.            QuickBASIC version of RegKey directly  from me. For information  on
  3101.            how to get in touch with me, please see page 71.  For a list of the
  3102.            files included  in  the  version of  RegKey  for  each  programming
  3103.            language, please see the section which begins on page 73.
  3104.  
  3105.            There  are  three  files  that   form  the  RegKey  interface   for
  3106.            QuickBASIC. The REGKEYQB.QLB  Quick Library contains  a version  of
  3107.            the RegKey  routines  for  use within  the  QuickBASIC  development
  3108.            environment  (QB.EXE).  In   order  to  use   RegKey  from   within
  3109.            QuickBASIC, you must start up QuickBASIC using the command:
  3110.  
  3111.                 QB \LREGKEYQB.QLB
  3112.  
  3113.            REGKEYQB.LIB   is   a   stand-alone   library   corresponding    to
  3114.            REGKEYQB.QLB,  and  is  automatically   used  by  QuickBASIC   when
  3115.            producing  an  executable   (.EXE)  file  of   your  program.   The
  3116.            REGKEYQB.BI file  provides QuickBASIC  with information  concerning
  3117.            the routines contained in the REGKEYQB.??? library files, and  must
  3118.            be included in any QuickBASIC program that uses RegKey. To do this,
  3119.            the $INCLUDE metacommand is used as follows:
  3120.  
  3121.                 ' $INCLUDE: 'regkeyqb.bi'
  3122.  
  3123.            For an example of  a QuickBASIC program that uses  RegKey, see the
  3124.            DEMOAPPD.BAS program.
  3125.  
  3126.            Below, the calling format for each  of the RegKey API functions  is
  3127.            documented from the perspective of the BASIC programming language:
  3128.  
  3129.  
  3130.  
  3131.  
  3132.  
  3133.  
  3134.  
  3135.  
  3136.  -----------------------------------------------------------------------------
  3137.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 56
  3138.  
  3139.  
  3140.  -----------------------------------------------------------------------------
  3141.  LANGUAGE  QuickBASIC and Visual Basic
  3142.  
  3143.  FUNCTION  RegKeyNewCodeSet()
  3144.  
  3145.  PURPOSE   Creates a new generation / validation code set
  3146.  
  3147.  FORMAT    Result% = RegKeyNewCodeSet%(sGenerationCode$, sValidationCode$)
  3148.  
  3149.  RETURNS   In QuickBASIC: RKSuccess on success, RKFailure on failure.
  3150.            In Visual Basic: 1 on success, 0 on failure.
  3151.  
  3152.  PARAMS    sGenerationCode$    - INPUT: 10-digit generation code string
  3153.            sValidationCode$    - OUTPUT: 10-digit validation code string
  3154.  
  3155.  NOTES     Generates a  registration  key  validation code corresponding  to a
  3156.            generation code.  This set  of generation  and validation  codes is
  3157.            unique for each application using RegKey, and determines the unique
  3158.            registration key that corresponds to a particular user's name.  The
  3159.            secret generation code is used at registration key generation time,
  3160.            and  the  corresponding  validation   code  is  used  within   your
  3161.            application when validating a registration key. The validation  and
  3162.            generation codes are  each represented  as a  ten-digit strings  of
  3163.            numbers and upper-case letters. This  function is called by  KeyGen
  3164.            or your own  utility, and is  only used once  for each  application
  3165.            using RegKey.
  3166.  
  3167.            The concepts of  code set creation are  introduced in  the section
  3168.            which begins on page 29.
  3169.  
  3170.  
  3171.  
  3172.  
  3173.  
  3174.  
  3175.  
  3176.  
  3177.  
  3178.  
  3179.  
  3180.  
  3181.  
  3182.  
  3183.  
  3184.  
  3185.  
  3186.  
  3187.  
  3188.  
  3189.  
  3190.  
  3191.  
  3192.  -----------------------------------------------------------------------------
  3193.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 57
  3194.  
  3195.  
  3196.  -----------------------------------------------------------------------------
  3197.  LANGUAGE  QuickBASIC and Visual Basic
  3198.  
  3199.  FUNCTION  RegKeyGenerate()
  3200.  
  3201.  PURPOSE   Creates a user-entered type registration key
  3202.  
  3203.  FORMAT    Result% = RegKeyGenerate%(sRegString$, sGenerationCode$,
  3204.            sRandomSeed$, sRegKey$)
  3205.  
  3206.  RETURNS   In QuickBASIC: RKSuccess on success, RKFailure on failure.
  3207.            In Visual Basic: 1 on success, 0 on failure.
  3208.  
  3209.  PARAMS    sRegString$         - INPUT: Registration string
  3210.            sGenerationCode$    - INPUT: Application's generation code string
  3211.            sRandomSeed$        - INPUT: Random number seed string
  3212.            sRegKey$            - OUTPUT: 20-digit registration key string
  3213.  
  3214.  NOTES     Generates a  registration  key for  a  particular user,  using  the
  3215.            secret generation code corresponding  to  a particular  application
  3216.            (as passed  to  RegKeyNewCodeSet()).  The  registration  string  is
  3217.            usually the name of the registered user, but may also contain other
  3218.            information, such as the version registered or date of expiry.  The
  3219.            registration string may be  zero to 64K  characters in length.  The
  3220.            registration key is returned as a string of letters and  upper-case
  3221.            letters. sRandomSeed$ should contain  10 random numbers and  upper-
  3222.            case numbers,  which  are  required  during  the  registration  key
  3223.            generation process.
  3224.  
  3225.            This function  is called  by KeyGen or  your  own  registration key
  3226.            generation utility, each time a registration key is generated for a
  3227.            new user. This function is used for user-entered registration keys;
  3228.            compare with RegKeyFileGenerate().
  3229.  
  3230.            Concepts of  registration  key  generation are  introduced  in  the
  3231.            section which begins on page 31.
  3232.  
  3233.  
  3234.  
  3235.  
  3236.  
  3237.  
  3238.  
  3239.  
  3240.  
  3241.  
  3242.  
  3243.  
  3244.  
  3245.  
  3246.  
  3247.  
  3248.  -----------------------------------------------------------------------------
  3249.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 58
  3250.  
  3251.  
  3252.  -----------------------------------------------------------------------------
  3253.  LANGUAGE  QuickBASIC and Visual Basic
  3254.  
  3255.  FUNCTION  RegKeyValidate()
  3256.  
  3257.  PURPOSE   Checks the validity of a user-entered registration key
  3258.  
  3259.  FORMAT    Result% = RegKeyValidate%(sRegString$, sRegKey$, sValidationCode$,
  3260.            sYourName$, nYourKey AS LONG, peRegistered AS INTEGER)
  3261.  
  3262.  RETURNS   In QuickBASIC: RKSuccess on success, RKFailure on failure.
  3263.            In Visual Basic: 1 on success, 0 on failure.
  3264.  
  3265.  PARAMS    sRegString$         - INPUT: Registration string
  3266.            sRegKey$            - INPUT: 20-digit registration key
  3267.            sValidationCode$    - INPUT: Application's validation code
  3268.            sYourName$          - INPUT: Your name (if registered)
  3269.            nYourKey&           - INPUT: Your key (if registered)
  3270.            peRegistered%       - OUTPUT: Is key valid
  3271.  
  3272.  NOTES     Checks whether  a given  registration string and  registration  key
  3273.            combination is  valid  for  a  particular  application,  using  the
  3274.            application-specific  validation   code  that   was  generated   by
  3275.            RegKeyNewCodeSet(). The integer passed as peRegistered is set to  0
  3276.            (or RKUnregistered in  QuickBASIC) if the  registration key is  not
  3277.            valid, and  is set  to 1  (or RKRegistered  in QuickBASIC)  if  the
  3278.            registration key is valid. If you have registered RegKey, your  own
  3279.            name and RegKey registration key should be passed to this  function
  3280.            to disable the RegKey "unregistered" message.
  3281.  
  3282.            This function is called from within  your application each time  it
  3283.            executes, in  order  to  determine whether  it  should  operate  in
  3284.            registered or unregistered mode. This  function is used with  user-
  3285.            entered registration keys; compare with RegKeyFileValidate().
  3286.  
  3287.            Concepts of  registration  key  validation are  introduced  in  the
  3288.            section which begins on page 34.
  3289.  
  3290.  
  3291.  
  3292.  
  3293.  
  3294.  
  3295.  
  3296.  
  3297.  
  3298.  
  3299.  
  3300.  
  3301.  
  3302.  
  3303.  
  3304.  -----------------------------------------------------------------------------
  3305.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 59
  3306.  
  3307.  
  3308.  -----------------------------------------------------------------------------
  3309.  LANGUAGE  QuickBASIC and Visual Basic
  3310.  
  3311.  FUNCTION  RegKeyFileGenerate()
  3312.  
  3313.  PURPOSE   Generates a file-based registration key
  3314.  
  3315.  FORMAT    Result% = RegKeyFileGenerate%(sRegString$, sGenerationCode$,
  3316.            sRandomSeed$, sFileName$)
  3317.  
  3318.  RETURNS   In QuickBASIC: RKSuccess on success, RKFailure on failure.
  3319.            In Visual Basic: 1 on success, 0 on failure.
  3320.  
  3321.  PARAMS    sRegString$         - INPUT: Registration string
  3322.            sGenerationCode$    - INPUT: Application's generation code string
  3323.            sRandomSeed$        - INPUT: Random number seed string
  3324.            sFileName$          - INPUT: Registration key file name string
  3325.  
  3326.  NOTES     Generates a  file-based registration  key  for a  particular  user,
  3327.            using the  secret generation  code  corresponding  to  a particular
  3328.            application (as  passed  to RegKeyNewCodeSet()).  The  registration
  3329.            string is usually  the name of  the registered user,  but may  also
  3330.            contain other information, such as  the version registered or  date
  3331.            of  expiry.  A  registration  key  file  is  generated,  using  the
  3332.            specified filename,  containing  the registration  string  and  the
  3333.            resulting registration  key.  If a  file  with the  specified  name
  3334.            already exists, it is  overwritten. sRandomSeed$ should contain  10
  3335.            random numbers and  upper-case letters, which  are required  during
  3336.            the registration key generation process.
  3337.  
  3338.            This function  is called  by KeyGen or  your own  registration  key
  3339.            generation utility, each time a registration key is generated for a
  3340.            new user. This function is  used for file-based registration  keys;
  3341.            compare with RegKeyGenerate().
  3342.  
  3343.            Concepts of  registration  key  generation are  introduced  in  the
  3344.            section which begins on page 31.
  3345.  
  3346.  
  3347.  
  3348.  
  3349.  
  3350.  
  3351.  
  3352.  
  3353.  
  3354.  
  3355.  
  3356.  
  3357.  
  3358.  
  3359.  
  3360.  -----------------------------------------------------------------------------
  3361.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 60
  3362.  
  3363.  
  3364.  -----------------------------------------------------------------------------
  3365.  LANGUAGE  QuickBASIC and Visual Basic
  3366.  
  3367.  FUNCTION  RegKeyFileValidate()
  3368.  
  3369.  PURPOSE   Checks the validity of a file-based registration key
  3370.  
  3371.  FORMAT    Result% = RegKeyFileValidate%(sFileName$, sValidationCode$,
  3372.            sYourName$, nYourKey AS LONG, sRegString$, cbMaxStringSize AS
  3373.            INTEGER, peRegistered AS INTEGER)
  3374.  
  3375.  RETURNS   In QuickBASIC: RKSuccess on success, RKFailure on failure.
  3376.            In Visual Basic: 1 on success, 0 on failure.
  3377.  
  3378.  PARAMS    sFileName$          - INPUT: Registration key file name string
  3379.            sValidationCode$    - INPUT: App's validation code string
  3380.            sYourName$          - INPUT: Your name (if registered)
  3381.            nYourKey            - INPUT: Your key (if registered)
  3382.            sRegString$         - OUTPUT: Registration string
  3383.            cbMaxStringSize%    - INPUT: Maximum size of registration string
  3384.            peRegistered&       - OUTPUT: Is key valid
  3385.  
  3386.  NOTES     Checks whether the specified registration key  file is valid for  a
  3387.            particular application, using the application-specified  validation
  3388.            code that was generated  by RegKeyNewCodeSet().  The integer passed
  3389.            as peRegistered is set  to 0 (or  RKUnregistered  in QuickBASIC) if
  3390.            the registration key is not valid, and is set to 1 (or RKRegistered
  3391.            in QuickBASIC) if  the registration  key is  valid. The  szFileName
  3392.            parameter may  include wildcards.  If you  have registered  RegKey,
  3393.            your own name and RegKey registration key should be passed to  this
  3394.            function to disable the RegKey "unregistered" message.
  3395.  
  3396.            The integer  cbMaxString  size  indicates  the  maximum  number  if
  3397.            characters that should  be placed in  the sRegString$ string.  With
  3398.            QuickBASIC, this may be any value from 1 to 255. With Visual Basic,
  3399.            this may be any value from 1 to 30,000.
  3400.  
  3401.            This function is called from within  your application each time  it
  3402.            executes, in  order  to  determine whether  it  should  operate  in
  3403.            registered or unregistered mode. This  function is used with  file-
  3404.            based registration keys; compare with RegKeyValidate().
  3405.  
  3406.            Concepts of  registration  key  validation are  introduced  in  the
  3407.            section which begins on page 34.
  3408.  
  3409.  
  3410.  
  3411.  
  3412.  
  3413.  
  3414.  
  3415.  
  3416.  -----------------------------------------------------------------------------
  3417.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 61
  3418.  
  3419.  
  3420.  USING THE REGKEY SYSTEM WITH VISUAL BASIC
  3421.  -----------------------------------------------------------------------------
  3422.  
  3423.            This section describes how to use  RegKey in programs written  with
  3424.            Microsoft Visual Basic for Windows. For information on using RegKey
  3425.            with Visual Basic for DOS, see page 56. RegKey has been tested with
  3426.            version 2.0 of  Visual Basic for  Windows. This information  should
  3427.            also apply to version 1.0 and 3.0 of the Visual Basic system.
  3428.  
  3429.            In order to use the Visual  Basic version of RegKey, you must  have
  3430.            the RegKey package RKEY31VB.ZIP. If you have the version of  RegKey
  3431.            designed for a different programming  language, you may obtain  the
  3432.            Visual Basic version of RegKey directly from me. For information on
  3433.            how to get in touch with me, please see page 71.  For a list of the
  3434.            files included  in  the  version of  RegKey  for  each  programming
  3435.            language, please see the section which begins on page 73.
  3436.  
  3437.            The RegKey interface for Visual  Basic consists of two  components:
  3438.            the REGKEYVB.BAS  module  that you  include  in your  Visual  Basic
  3439.            project, and  the  RK31VB.DLL file  that  is used  to  generate  or
  3440.            validate registration  keys  during your  program's  execution.  To
  3441.            include REGKEYVB.BAS in your  program, choose the File|Add  File...
  3442.            option from within Visual Basic,  and then select the  REGKEYVB.BAS
  3443.            file. The REGKEYVB.BAS  module will  now appear  in your  program's
  3444.            project window within Visual Basic. You should not normally  change
  3445.            the contents  of  this file,  but  feel free  to  refer to  it  for
  3446.            reference to the  RegKey functions.  The role  of the  REGKEYVB.BAS
  3447.            module is to serve as a intermediate layer between your program and
  3448.            the RK31VB.DLL library, ensuring that strings passed to  RK31VB.DLL
  3449.            are large enough for it to return any necessary information to you.
  3450.  
  3451.            The RK31VB.DLL file must be present in the Windows system directory
  3452.            (typically C:\WINDOWS\SYSTEM)  whenever your  program is  run,  and
  3453.            should be distributed with your program. You may wish to provide an
  3454.            installation utility for  your software,  which will  automatically
  3455.            install the RK31VB.DLL file in the user's Windows system directory.
  3456.  
  3457.            For an example of a Visual Basic program that uses RegKey,  see the
  3458.            DemoAppW source  code  contained  in  the  files  DEMOAPPW.BAS  and
  3459.            DEMOAPPW.MAK.
  3460.  
  3461.            The calling  format  for  each  of  the  RegKey  API  functions  is
  3462.            documented from the perspective  of the BASIC programming  language
  3463.            beginning on page 57.
  3464.  
  3465.  
  3466.  
  3467.  
  3468.  
  3469.  
  3470.  
  3471.  
  3472.  -----------------------------------------------------------------------------
  3473.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 62
  3474.  
  3475.  
  3476.  USING THE REGKEY SYSTEM WITH TURBO PASCAL
  3477.  -----------------------------------------------------------------------------
  3478.  
  3479.            This section describes how to use  RegKey in programs written  with
  3480.            Turbo Pascal. In order to use the  Turbo Pascal version  of RegKey,
  3481.            you must  have the  RegKey package  RKEY31TP.ZIP. If  you have  the
  3482.            version of RegKey  designed for a  different programming  language,
  3483.            you may obtain the Turbo Pascal version of RegKey directly from me.
  3484.            For information on how to get in touch with me, please see page 71.
  3485.            For a list of the files included in the version of RegKey for  each
  3486.            programming language, please see the  section which begins on  page
  3487.            73.
  3488.  
  3489.            The RegKey  package includes.TPU  units  that are  compatible  with
  3490.            Turbo Pascal for DOS 7.0 and Turbo  Pascal for Windows 1.0.  If you
  3491.            are using a  different version of  Turbo Pascal, you  will have  to
  3492.            follow the  instructions below  to build  a  RegKey unit  for  your
  3493.            version of Turbo Pascal. If you are using Turbo Pascal for DOS 7.0,
  3494.            simply rename the included REGKEYD7.TPU file to REGKEYD.TPU. If you
  3495.            are using  Turbo  Pascal  for  Windows  1.0,  rename  the  included
  3496.            REGKEYW1.TPU file to REGKEYW.TPU. You  can then skip the  following
  3497.            instructions for building a RegKey unit.
  3498.  
  3499.            If you  are using  any version  of Turbo  Pascal other  than  Turbo
  3500.            Pascal for DOS 7.0 or Turbo  Pascal for Windows 1.0, you will  have
  3501.            to first build  a .TPU unit  for your version  of Turbo Pascal.  In
  3502.            order to  do  this,  you  will need  to  have  the  following  file
  3503.            (included in the RegKey package)  located in the current  directory
  3504.            or your Turbo Pascal working directory:
  3505.  
  3506.            FOR DOS:       REGKEYD.PAS
  3507.                           RKFGEND.OBJ
  3508.                           RKFILED.OBJ
  3509.                           RKFVALD.OBJ
  3510.                           RKGEND.OBJ
  3511.                           RKMATHD.OBJ
  3512.                           RKNSETD.OBJ
  3513.                           RKRD.OBJ
  3514.                           RKTPD.OBJ
  3515.                           RKVALD.OBJ
  3516.  
  3517.            For Windows:   REGKEYW.PAS
  3518.  
  3519.            The Turbo  Pascal/DOS RegKey  unit is  built from  the  REGKEYD.PAS
  3520.            file. You can build this unit from the DOS command prompt using the
  3521.            TPC compiler,  or from  within the  TURBO development  environment.
  3522.            From  the  command  line,  type   TPC  REGKEYD.PAS  to  build   the
  3523.            REGKEYD.TPU unit. From  within the  TURBO development  environment,
  3524.            open the REGKEYD.PAS source file for DOS, or the REGKEYW.PAS source
  3525.            file  for  Windows.  From  the  Compile  menu  choose  File  as   a
  3526.            destination, and then choose the "Make" command.
  3527.  
  3528.  -----------------------------------------------------------------------------
  3529.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 63
  3530.  
  3531.  
  3532.  
  3533.            The Turbo Pascal/Windows RegKey unit is built from the  REGKEYW.PAS
  3534.            file. You can build this unit from within Turbo Pascal for  Windows
  3535.            by opening the REGKEYW.PAS file and choosing the Compile|Make  menu
  3536.            option.
  3537.  
  3538.            Once you have built a RegKey unit for your version of Turbo Pascal,
  3539.            you can either  place it in  the same directory  as your  program's
  3540.            .PAS source code  files, or you  can place it  in the Turbo  Pascal
  3541.            UNITS directory.
  3542.  
  3543.            To call any  of the  RegKey functions  from within  a Turbo  Pascal
  3544.            program, you must place a uses clause at the start of your program,
  3545.            and include RegKeyD (for DOS) or RegKeyW (for Windows) in the  list
  3546.            of units. For example:
  3547.  
  3548.                 program TestAppD;
  3549.                 uses RegKeyD, Graph;
  3550.  
  3551.            In addition, if you are using Turbo Pascal/Windows, the  RK31TP.DLL
  3552.            file must reside in the Windows/System directory when your  program
  3553.            is run. As a  result, you must include  the RK31TP.DLL file in  the
  3554.            installation of your program.
  3555.  
  3556.            For an example of a Turbo Pascal/DOS program that uses RegKey,  see
  3557.            the DEMOAPPD.PAS program that is  included in your RegKey  package.
  3558.            For an example of a Turbo Pascal/Windows program that uses  RegKey,
  3559.            see the DEMOAPPW.PAS program.
  3560.  
  3561.            Below, the calling format for each  of the RegKey API functions  is
  3562.            documented from the perspective of the BASIC programming language:
  3563.  
  3564.  
  3565.  
  3566.  
  3567.  
  3568.  
  3569.  
  3570.  
  3571.  
  3572.  
  3573.  
  3574.  
  3575.  
  3576.  
  3577.  
  3578.  
  3579.  
  3580.  
  3581.  
  3582.  
  3583.  
  3584.  -----------------------------------------------------------------------------
  3585.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 64
  3586.  
  3587.  
  3588.  -----------------------------------------------------------------------------
  3589.  LANGUAGE  Turbo Pascal
  3590.  
  3591.  FUNCTION  RegKeyNewCodeSet()
  3592.  
  3593.  PURPOSE   Creates a new generation / validation code set
  3594.  
  3595.  FORMAT    function RegKeyNewCodeSet(
  3596.                  sGenerationCode : string;
  3597.                  sValidationCode : string)
  3598.               : RKReturn;
  3599.  
  3600.  RETURNS   Enumeration type RKReturn. Value of RKSuccess on success, RKFailure
  3601.            on failure.
  3602.  
  3603.  PARAMS    sGenerationCode     - INPUT: 10-digit generation code string
  3604.            sValidationCode     - OUTPUT: 10-digit validation code string
  3605.  
  3606.  NOTES     Generates a  registration key  validation code  corresponding  to a
  3607.            generation code. This set  of generation  and  validation  codes is
  3608.            unique for each application using RegKey, and determines the unique
  3609.            registration key that corresponds to a particular user's name.  The
  3610.            secret generation code is used at registration key generation time,
  3611.            and  the  corresponding  validation   code  is  used  within   your
  3612.            application when validating a registration key. The validation  and
  3613.            generation codes are  each represented  as a  ten-digit strings  of
  3614.            numbers and upper-case letters. This  function is called by  KeyGen
  3615.            or your own  utility, and is  only used once  for each  application
  3616.            using RegKey.
  3617.  
  3618.            The concepts of  code set creation are  introduced in  the section
  3619.            which begins on page 29.
  3620.  
  3621.  
  3622.  
  3623.  
  3624.  
  3625.  
  3626.  
  3627.  
  3628.  
  3629.  
  3630.  
  3631.  
  3632.  
  3633.  
  3634.  
  3635.  
  3636.  
  3637.  
  3638.  
  3639.  
  3640.  -----------------------------------------------------------------------------
  3641.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 65
  3642.  
  3643.  
  3644.  -----------------------------------------------------------------------------
  3645.  LANGUAGE  Turbo Pascal
  3646.  
  3647.  FUNCTION  RegKeyGenerate()
  3648.  
  3649.  PURPOSE   Creates a user-entered type registration key
  3650.  
  3651.  FORMAT    function RegKeyGenerate(
  3652.                  sRegString      : string;
  3653.                  sGenerationCode : string;
  3654.                  sRandomSeed     : string;
  3655.                  sRegKey         : string)
  3656.               : RKReturn;
  3657.  
  3658.  RETURNS   Enumeration type RKReturn. Value of RKSuccess on success, RKFailure
  3659.            on failure.
  3660.  
  3661.  PARAMS    sRegString          - INPUT: Registration string
  3662.            sGenerationCode     - INPUT: Application's generation code string
  3663.            sRandomSeed         - INPUT: Random number seed string
  3664.            sRegKey             - OUTPUT: 20-digit registration key string
  3665.  
  3666.  NOTES     Generates a  registration  key for  a  particular user,  using  the
  3667.            secret generation code  corresponding to  a particular  application
  3668.            (as passed  to  RegKeyNewCodeSet()).  The  registration  string  is
  3669.            usually the name of the registered user, but may also contain other
  3670.            information, such as the version registered or date of expiry.  The
  3671.            registration key is returned in sRegKey as a string of letters  and
  3672.            upper-case letters. The string passed in sRegKey should be at least
  3673.            20 characters in size. sRandomSeed should contain 10 random numbers
  3674.            and upper-case numbers, which are required during the  registration
  3675.            key generation process.
  3676.  
  3677.            This function  is called  by KeyGen or  your own  registration  key
  3678.            generation utility, each time a registration key is generated for a
  3679.            new user. This function is used for user-entered registration keys;
  3680.            compare with RegKeyFileGenerate().
  3681.  
  3682.            Concepts of  registration  key  generation are  introduced  in  the
  3683.            section which begins on page 31.
  3684.  
  3685.  
  3686.  
  3687.  
  3688.  
  3689.  
  3690.  
  3691.  
  3692.  
  3693.  
  3694.  
  3695.  
  3696.  -----------------------------------------------------------------------------
  3697.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 66
  3698.  
  3699.  
  3700.  -----------------------------------------------------------------------------
  3701.  LANGUAGE  Turbo Pascal
  3702.  
  3703.  FUNCTION  RegKeyValidate()
  3704.  
  3705.  PURPOSE   Checks the validity of a user-entered registration key
  3706.  
  3707.  FORMAT    function RegKeyValidate(
  3708.                  sRegString       : string;
  3709.                  sRegKey          : string;
  3710.                  sValidationCode  : string;
  3711.                  sYourName        : string;
  3712.                  nYourKey         : longint;
  3713.                  var peRegistered : RKValid)
  3714.               : RKReturn;
  3715.  
  3716.  RETURNS   Enumeration type RKReturn. Value of RKSuccess on success, RKFailure
  3717.            on failure.
  3718.  
  3719.  PARAMS    sRegString          - INPUT: Registration string
  3720.            sRegKey             - INPUT: 20-digit registration key
  3721.            sValidationCode     - INPUT: Application's validation code
  3722.            sYourName           - INPUT: Your name (if registered)
  3723.            nYourKey            - INPUT: Your key (if registered)
  3724.            peRegistered        - OUTPUT: Is key valid
  3725.  
  3726.  NOTES     Checks whether  a given  registration string and  registration  key
  3727.            combination is  valid  for  a  particular  application,  using  the
  3728.            application-specific  validation   code  that   was  generated   by
  3729.            RegKeyNewCodeSet(). The parameter peRegistered should be a variable
  3730.            of type RKValid. This variable is set to the value RKRegistered  if
  3731.            the registration  key is  valid, and  RKUnregistered if  it is  not
  3732.            valid. If  you have  registered RegKey,  your own  name and  RegKey
  3733.            registration key should be passed to  this function to disable  the
  3734.            RegKey "unregistered" message.
  3735.  
  3736.            This function is called from within  your application each time  it
  3737.            executes, in  order  to  determine whether  it  should  operate  in
  3738.            registered or unregistered mode. This  function is used with  user-
  3739.            entered registration keys; compare with RegKeyFileValidate().
  3740.  
  3741.            Concepts of  registration  key  validation are  introduced  in  the
  3742.            section which begins on page 34.
  3743.  
  3744.  
  3745.  
  3746.  
  3747.  
  3748.  
  3749.  
  3750.  
  3751.  
  3752.  -----------------------------------------------------------------------------
  3753.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 67
  3754.  
  3755.  
  3756.  -----------------------------------------------------------------------------
  3757.  LANGUAGE  Turbo Pascal
  3758.  
  3759.  FUNCTION  RegKeyFileGenerate()
  3760.  
  3761.  PURPOSE   Generates a file-based registration key
  3762.  
  3763.  FORMAT    function RegKeyFileGenerate(
  3764.                  sRegString      : string;
  3765.                  sGenerationCode : string;
  3766.                  sRandomSeed     : string;
  3767.                  sFileName       : string)
  3768.               : RKReturn;
  3769.  
  3770.  RETURNS   Enumeration type RKReturn. Value of RKSuccess on success, RKFailure
  3771.            on failure.
  3772.  
  3773.  PARAMS    sRegString          - INPUT: Registration string
  3774.            sGenerationCode     - INPUT: Application's generation code string
  3775.            sRandomSeed         - INPUT: Random number seed string
  3776.            sFileName           - INPUT: Registration key file name string
  3777.  
  3778.  NOTES     Generates a  file-based registration  key  for a  particular  user,
  3779.            using the  secret generation  code corresponding  to  a  particular
  3780.            application (as  passed  to RegKeyNewCodeSet()).  The  registration
  3781.            string is usually  the name of  the registered user,  but may  also
  3782.            contain other information, such as  the version registered or  date
  3783.            of  expiry.  A  registration  key  file  is  generated,  using  the
  3784.            specified filename,  containing  the registration  string  and  the
  3785.            resulting registration  key.  If a  file  with the  specified  name
  3786.            already exists, it  is overwritten. sRandomSeed  should contain  10
  3787.            random numbers and  upper-case letters, which  are required  during
  3788.            the registration key generation process.
  3789.  
  3790.            This function  is called  by KeyGen or  your own  registration  key
  3791.            generation utility, each time a registration key is generated for a
  3792.            new user. This function is  used for file-based registration  keys;
  3793.            compare with RegKeyGenerate().
  3794.  
  3795.            Concepts of  registration  key  generation are  introduced  in  the
  3796.            section which begins on page 31.
  3797.  
  3798.  
  3799.  
  3800.  
  3801.  
  3802.  
  3803.  
  3804.  
  3805.  
  3806.  
  3807.  
  3808.  -----------------------------------------------------------------------------
  3809.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 68
  3810.  
  3811.  
  3812.  -----------------------------------------------------------------------------
  3813.  LANGUAGE  Turbo Pascal
  3814.  
  3815.  FUNCTION  RegKeyFileValidate()
  3816.  
  3817.  PURPOSE   Checks the validity of a file-based registration key
  3818.  
  3819.  FORMAT    function RegKeyFileValidate(
  3820.                  sFileName        : string;
  3821.                  sValidationCode  : string;
  3822.                  sYourName        : string;
  3823.                  nYourKey         : longint;
  3824.                  sRegString       : string;
  3825.                  cbMaxStringSize  : byte;
  3826.                  var peRegistered : RKValid)
  3827.               : RKReturn;
  3828.  
  3829.  RETURNS   Enumeration type RKReturn. Value of RKSuccess on success, RKFailure
  3830.            on failure.
  3831.  
  3832.  PARAMS    sFileName           - INPUT: Registration key file name string
  3833.            sValidationCode     - INPUT: App's validation code string
  3834.            sYourName           - INPUT: Your name (if registered)
  3835.            nYourKey            - INPUT: Your key (if registered)
  3836.            sRegString          - OUTPUT: Registration string
  3837.            cbMaxStringSize     - INPUT: Maximum size of registration string
  3838.            peRegistered        - OUTPUT: Is key valid
  3839.  
  3840.  NOTES     Checks whether the specified registration key  file is valid for  a
  3841.            particular application, using the application-specified  validation
  3842.            code  that  was  generated  by  RegKeyNewCodeSet().  The  parameter
  3843.            peRegistered should be a variable of type RKValid. This variable is
  3844.            set to the value RKRegistered if the registration key is valid, and
  3845.            RKUnregistered if it is not valid.  If you have registered  RegKey,
  3846.            your own name and RegKey registration key should be passed to  this
  3847.            function to disable the RegKey "unregistered" message.
  3848.  
  3849.            The integer  cbMaxString  size  indicates  the  maximum  number  if
  3850.            characters that  should be  placed in  the sRegString  string,  and
  3851.            should be equal  to the size  of the passed  string as declared  in
  3852.            Turbo Pascal, or 255 if  no size was specified  when declaring  the
  3853.            string.
  3854.  
  3855.            This function is called from within  your application each time  it
  3856.            executes, in  order  to  determine whether  it  should  operate  in
  3857.            registered or unregistered mode. This  function is used with  file-
  3858.            based registration keys; compare with RegKeyValidate().
  3859.  
  3860.            Concepts of  registration  key  validation are  introduced  in  the
  3861.            section which begins on page 34.
  3862.  
  3863.  
  3864.  -----------------------------------------------------------------------------
  3865.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 69
  3866.  
  3867.  
  3868.  USING REGKEY WITH OTHER LANGUAGES OR OPERATING SYSTEMS
  3869.  -----------------------------------------------------------------------------
  3870.  
  3871.            If you  are  working  with  a  programming  language,  compiler  or
  3872.            operating system that  is not specifically  addressed in the  above
  3873.            sections, it may still be possible for you to use RegKey. There are
  3874.            three possible options:
  3875.  
  3876.           A.) Calling routines from the included RegKey library files
  3877.           B.) Obtaining the RegKey source code and porting it
  3878.           C.) Obtaining a custom version of RegKey from me
  3879.  
  3880.            Each of these options are described in more detail below:
  3881.  
  3882.           A.) Many PC-based  programming languages have  the ability to  call
  3883.               functions using the C calling conventions, from Intel/Microsoft
  3884.               object format library files. For information on how to  do this
  3885.               in the language you  are using, see  the documentation that  is
  3886.               included with your language.  This documentation will  probably
  3887.               refer to  the  function  names and  parameters  (known  as  the
  3888.               function prototype) of the  C language functions to  be called.
  3889.               The pertinent information on  the C functions that  form RegKey
  3890.               is described in the section beginning on page 47.
  3891.  
  3892.           B.) As  is  described  on  page  13,  the  RegKey  source  code  is
  3893.               available.  RegKey  is  written  in  ANSI-compliant  C  and  is
  3894.               designed to be  easily ported  to other  hardware platforms  or
  3895.               operating systems. While the  source code package does  include
  3896.               80x86 assembly language routines  for performing certain  tasks
  3897.               such as 96-bit  arithmetic, the  equivalent C  source code  for
  3898.               these routines is also included.
  3899.  
  3900.           C.) I may  also be  willing to  port  RegKey to  another  operating
  3901.               system, hardware platform or  programming language for you.  To
  3902.               do this, I usually require  that you (LEGALLY) furnish  me with
  3903.               the necessary  software  and/or  hardware to  create  a  custom
  3904.               version of RegKey. If I am able to keep the software / hardware
  3905.               and use it to produce future  versions of RegKey for  others, I
  3906.               would generally provide you with a free RegKey registration and
  3907.               copy of the source  code, but no more.  If you wish to  discuss
  3908.               this possibility further, please feel free to get in touch with
  3909.               me. For more information how to reach me, see page 71.
  3910.  
  3911.  
  3912.  
  3913.  
  3914.  
  3915.  
  3916.  
  3917.  
  3918.  
  3919.  
  3920.  -----------------------------------------------------------------------------
  3921.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 70
  3922.  
  3923.  
  3924.  -----------------------------------------------------------------------------
  3925.  PART 5: ADDITIONAL INFORMATION
  3926.  -----------------------------------------------------------------------------
  3927.  
  3928.  
  3929.  
  3930.  GETTING HELP
  3931.  -----------------------------------------------------------------------------
  3932.  
  3933.            If you have  any questions  about RegKey,  would like  help with  a
  3934.            program that your are writing, or  have any suggestions for  future
  3935.            versions of RegKey, please feel free to get in touch with me.
  3936.  
  3937.            If you  are  having difficulties  with  RegKey, the  more  detailed
  3938.            information you supply (such as source code to the program that  is
  3939.            causing the problem, how to duplicate the problem, etc.), the  more
  3940.            quickly I will be able to determine the cause of your problem.
  3941.  
  3942.            If you would like  to receive the most  recent copy of RegKey,  you
  3943.            can download  it  from the  RegKey  support bulletin  board  system
  3944.            (phone number  below), file  request it  from the  FidoNet  address
  3945.            below, or send three dollars ($3) to cover the cost of postage  and
  3946.            a diskette to the address listed below.
  3947.  
  3948.            You can get in touch with me by any of the following means:
  3949.  
  3950.           -  By conventional mail. My postal address is:
  3951.  
  3952.                           Brian Pirie
  3953.                           Apt. 1416 - 2201 Riverside Dr.
  3954.                           Ottawa, Ontario
  3955.                           K1H 8K9
  3956.                           Canada
  3957.  
  3958.           -  By electronic mail. My Internet e-mail address is:
  3959.  
  3960.                           brian@bpecomm.ocunix.on.ca
  3961.  
  3962.              And my FidoNet netmail address is:
  3963.  
  3964.                           1:243/8   ***SEE NOTE BELOW***
  3965.  
  3966.              If you  have access  to an  on-line service  such as  Prodigy or
  3967.              CompuServe, you can also reach me by sending Internet e-mail. On
  3968.              CompuServe, send mail to:
  3969.  
  3970.                      INTERNET:brian@bpecomm.ocunix.on.ca
  3971.  
  3972.              While I would like  to be able to  reply to all  FidoNet NetMail
  3973.              messages by CrashMail, I am afraid I can not  afford to do this.
  3974.              So, if you choose  to send NetMail, please  indicate whether you
  3975.  
  3976.  -----------------------------------------------------------------------------
  3977.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 71
  3978.  
  3979.  
  3980.              would like me to reply by routed NetMail (this  may not work, if
  3981.              routed NetMail is not available  in your area), or  to place the
  3982.              message on hold for you to poll and pick up.
  3983.  
  3984.           -  By calling the RegKey  support bulletin board system.  The phone
  3985.              number for the support BBS is:
  3986.  
  3987.                           +1 613 526 4466
  3988.  
  3989.              The  BBS  supports  speeds  up  to  9600bps,  with  v.32/v.42bis
  3990.              capabilities. You are  given full access  to the support  BBS on
  3991.              your first call. In addition  to being able to  reach me through
  3992.              the support BBS,  you can  also download  the newest  version of
  3993.              RegKey, and other  software that  may be  of interest  to people
  3994.              using RegKey.
  3995.  
  3996.            I try to respond to all correspondences as soon as possible  (i.e.,
  3997.            within twenty-four hours). However, it is possible that it may take
  3998.            longer to reply to your message,  particularly if you are asking  a
  3999.            question that requires time for me to get an answer, or if I happen
  4000.            to be away for a few days.
  4001.  
  4002.  
  4003.  
  4004.  
  4005.  
  4006.  
  4007.  
  4008.  
  4009.  
  4010.  
  4011.  
  4012.  
  4013.  
  4014.  
  4015.  
  4016.  
  4017.  
  4018.  
  4019.  
  4020.  
  4021.  
  4022.  
  4023.  
  4024.  
  4025.  
  4026.  
  4027.  
  4028.  
  4029.  
  4030.  
  4031.  
  4032.  -----------------------------------------------------------------------------
  4033.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 72
  4034.  
  4035.  
  4036.  CONTENTS OF PACKAGE
  4037.  -----------------------------------------------------------------------------
  4038.  
  4039.            The files included  in the disk  or archive in  which you  received
  4040.            your copy of RegKey will vary depending upon which language version
  4041.            of RegKey  you  have received.  Different  versions of  RegKey  are
  4042.            available for each of the following programming languages:
  4043.  
  4044.                 RKEY31C.ZIP    C/C++ (DOS & Windows) version of RegKey
  4045.                 RKEY31TP.ZIP   Turbo Pascal (DOS & Windows) version of RegKey
  4046.                 RKEY31QB.ZIP   QuickBASIC (DOS) version of RegKey
  4047.                 RKEY31VB.ZIP   VisualBasic (Windows) version of RegKey
  4048.  
  4049.            If you do not have the  correct RegKey package for the  programming
  4050.            language you are using, you may obtain the newest version of any of
  4051.            the RegKey packages directly from me. For information on how to  do
  4052.            this, please see page 71.
  4053.  
  4054.  
  4055.            The  following   files  compose   the  C/C++   version  of   RegKey
  4056.            (RKEY31C.ZIP)
  4057.  
  4058.                FILE_ID.DIZ     A brief description of the RegKey package
  4059.  
  4060.                REGKEYSD.LIB    DOS tiny/small memory model RegKey library
  4061.                REGKEYCD.LIB    DOS compact memory model RegKey library
  4062.                REGKEYMD.LIB    DOS medium memory model RegKey library
  4063.                REGKEYLD.LIB    DOS large/huge memory model RegKey library
  4064.                REGKEYSW.LIB    Windows small memory model RegKey library
  4065.                REGKEYCW.LIB    Windows compact memory model RegKey library
  4066.                REGKEYMW.LIB    Windows medium memory model RegKey library
  4067.                REGKEYLW.LIB    Windows large/huge memory model RegKey library
  4068.                REGKEYSP.MIX    Power C small memroy model RegKey library
  4069.                REGKEYMP.MIX    Power C medium memory model RegKey library
  4070.                REGKEYLP.MIX    Power C large memory model RegKey library
  4071.                REGKEY.H        C/C++ include file for RegKey
  4072.                DEMOAPPD.C      C language DOS version of example program
  4073.                DEMOAPPW.C      C language Windows version of example program
  4074.                DEMOAPPD.CPP    C++ language DOS version of example program
  4075.                DEMOAPPW.CPP    C++ language Windows version of example program
  4076.  
  4077.                KEYGEN.DAT      Data file used by key generation utility
  4078.                KEYGEND.EXE     DOS version of key generation utility
  4079.                KEYGENW.EXE     Windows version of key generation utility
  4080.                CTL3DV2.DLL     Used by Windows version of KeyGen
  4081.  
  4082.                DEMOAPPD.EXE    DOS version of the RegKey example program
  4083.                DEMOAPPW.EXE    Windows version of the RegKey example program
  4084.  
  4085.                ORDER.FRM       Easy to print RegKey order form
  4086.                REGKEY.TXT      The RegKey programmer's manual (this file).
  4087.  
  4088.  -----------------------------------------------------------------------------
  4089.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 73
  4090.  
  4091.  
  4092.  
  4093.  
  4094.            The following  files compose  the Turbo  Pascal version  of  RegKey
  4095.            (RKEY31TP.ZIP)
  4096.  
  4097.                FILE_ID.DIZ     A brief description of the RegKey package
  4098.  
  4099.                RKFGEND.OBJ     Object files for building RegKey TP/DOS unit
  4100.                RKFILED.OBJ             "                             "
  4101.                RKFVALD.OBJ             "                             "
  4102.                RKGEND.OBJ              "                             "
  4103.                RKMATHD.OBJ             "                             "
  4104.                RKNSETD.OBJ             "                             "
  4105.                RKRD.OBJ                "                             "
  4106.                RKTPD.OBJ               "                             "
  4107.                RKVALD.OBJ              "                             "
  4108.                REGKEYD.PAS     Pascal file for building RegKey TP/DOS unit
  4109.                REGKEYD7.TPU    RegKey Unit for Turbo Pascal 7.0 for DOS
  4110.                REGKEYW.PAS     Pascal file for building RegKey TP/Windows unit
  4111.                REGKEYW1.TPU    RegKey Unit For Turbo Pascal 1.0 for Widnows
  4112.                DEMOAPPD.PAS    Pascal/DOS version of RegKey example program
  4113.                DEMOAPPW.PAS    Pascal/Windows version of RegKey example prog.
  4114.  
  4115.                KEYGEN.DAT      Data file used by key generation utility
  4116.                KEYGEND.EXE     DOS version of key generation utility
  4117.                KEYGENW.EXE     Windows version of key generation utility
  4118.                CTL3DV2.DLL     Used by Windows version of KeyGen
  4119.  
  4120.                DEMOAPPD.EXE    DOS version of the RegKey example program
  4121.                DEMOAPPW.EXE    Windows version of the RegKey example program
  4122.  
  4123.                ORDER.FRM       Easy to print RegKey order form
  4124.                REGKEY.TXT      The RegKey programmer's manual (this file).
  4125.  
  4126.  
  4127.            The following  files  compose  the  QuickBASIC  version  of  RegKey
  4128.            (RKEY31QB.ZIP)
  4129.  
  4130.                FILE_ID.DIZ     A brief description of the RegKey package
  4131.  
  4132.                REGKEYQB.QLB    QuickBASIC Quick Library for RegKey
  4133.                REGKEYQB.LIB    QuickBASIC stand-alone library for RegKey
  4134.                REGKEYQB.BI     QuickBASIC include file for RegKey
  4135.                DEMOAPPD.BAS    QuickBASIC version of the example program
  4136.  
  4137.                KEYGEN.DAT      Data file used by key generation utility
  4138.                KEYGEND.EXE     DOS version of key generation utility
  4139.                KEYGENW.EXE     Windows version of key generation utility
  4140.                CTL3DV2.DLL     Used by Windows version of KeyGen
  4141.  
  4142.                DEMOAPPD.EXE    DOS version of the RegKey example program
  4143.  
  4144.  -----------------------------------------------------------------------------
  4145.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 74
  4146.  
  4147.  
  4148.  
  4149.                ORDER.FRM       Easy to print RegKey order form
  4150.                REGKEY.TXT      The RegKey programmer's manual (this file).
  4151.  
  4152.  
  4153.            The following  files compose  the Visual  Basic version  of  RegKey
  4154.            (RKEY31VB.ZIP)
  4155.  
  4156.                FILE_ID.DIZ     A brief description of the RegKey package
  4157.  
  4158.                RK31VB.DLL      RegKey .DLL callable from Visual Basic
  4159.                REGKEYVB.BAS    RegKey interface module for Visual Basic
  4160.                DEMOAPPW.BAS    Visual Basic version of the example program
  4161.                DEMOAPPW.MAK    Visual Basic project file for example program
  4162.  
  4163.                KEYGEN.DAT      Data file used by key generation utility
  4164.                KEYGEND.EXE     DOS version of key generation utility
  4165.                KEYGENW.EXE     Windows version of key generation utility
  4166.                CTL3DV2.DLL     Used by Windows version of KeyGen
  4167.  
  4168.                DEMOAPPW.EXE    Windows version of the RegKey example program
  4169.  
  4170.                ORDER.FRM       Easy to print RegKey order form
  4171.                REGKEY.TXT      The RegKey programmer's manual (this file).
  4172.  
  4173.  
  4174.  
  4175.  
  4176.  
  4177.  
  4178.  
  4179.  
  4180.  
  4181.  
  4182.  
  4183.  
  4184.  
  4185.  
  4186.  
  4187.  
  4188.  
  4189.  
  4190.  
  4191.  
  4192.  
  4193.  
  4194.  
  4195.  
  4196.  
  4197.  
  4198.  
  4199.  
  4200.  -----------------------------------------------------------------------------
  4201.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 75
  4202.  
  4203.  
  4204.  REVISION HISTORY
  4205.  -----------------------------------------------------------------------------
  4206.  
  4207.            RegKey 3.00, RegKey  3.10 and all  future versions  of RegKey  will
  4208.            recognize an identical registration key  format. As a result,  when
  4209.            upgrading from RegKey 3.00 or any later version, you are guaranteed
  4210.            compatibility with  registration  keys  already  created  for  your
  4211.            program. Also,  older  versions  of  your  program  will  recognize
  4212.            registration keys produced with newer versions of RegKey.
  4213.  
  4214.            The following changes  and enhancements  have been  made to  RegKey
  4215.            version 3.10:
  4216.  
  4217.           -  Previously, the files  for every programming  language supported
  4218.              by RegKey were distributed  in one package  (e.g. REGKEY30.ZIP).
  4219.              In order  to make  the  RegKey package  smaller  to download  or
  4220.              transfer, RegKey is now distributed in the following packages:
  4221.  
  4222.                      RKEY31C.ZIP    C/C++ version of RegKey
  4223.                      RKEY31TP.ZIP   Turbo Pascal version of RegKey
  4224.                      RKEY31QB.ZIP   QuickBASIC version of RegKey
  4225.                      RKEY31VB.ZIP   VisualBasic version of RegKey
  4226.  
  4227.              In order to simplify the use  of RegKey for those  who are using
  4228.              it with more than one programming language, all versions include
  4229.              the same manual.
  4230.  
  4231.           - Any  trailing  carriage  return or  line  feed  characters  in  a
  4232.              registration key  file are  ignored. With  version 3.00,  if the
  4233.              user attempted  to edit  the registration  key  file, some  text
  4234.              editors would add  a trailing end-of-line  character, destroying
  4235.              the registration  key file.  This change  has no  effect on  the
  4236.              behavior of user-entered registration keys.
  4237.  
  4238.           -  The RegKey  C  language package  now  includes  support for  Mix
  4239.              Software's Power C compiler.
  4240.  
  4241.           -  The RegKey Pascal language package now includes full support for
  4242.              Turbo Pascal for Windows. Although it was possible to use RegKey
  4243.              3.00 with Turbo  Pascal for  Windows, it  was necessary  to make
  4244.              some modifications to the REGKEYW.PAS file.
  4245.  
  4246.           -  When generating  user-entered  registration  keys,  the  Windows
  4247.              version of the KeyGen program now allows the registration key to
  4248.              be copied to the  Windows clipboard by  pressing a new  "copy to
  4249.              clipboard" button.
  4250.  
  4251.           -  The Windows versions of  the C and  C++ DemoApp source  code was
  4252.              accidentally omitted from the RegKey 3.00 package. This has been
  4253.              problem has been fixed for this version of RegKey.
  4254.  
  4255.  
  4256.  -----------------------------------------------------------------------------
  4257.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 76
  4258.  
  4259.  
  4260.           -  A number  of minor  improvements have  been made  to the  RegKey
  4261.              manual.
  4262.  
  4263.  
  4264.  
  4265.  
  4266.  
  4267.  
  4268.  
  4269.  
  4270.  
  4271.  
  4272.  
  4273.  
  4274.  
  4275.  
  4276.  
  4277.  
  4278.  
  4279.  
  4280.  
  4281.  
  4282.  
  4283.  
  4284.  
  4285.  
  4286.  
  4287.  
  4288.  
  4289.  
  4290.  
  4291.  
  4292.  
  4293.  
  4294.  
  4295.  
  4296.  
  4297.  
  4298.  
  4299.  
  4300.  
  4301.  
  4302.  
  4303.  
  4304.  
  4305.  
  4306.  
  4307.  
  4308.  
  4309.  
  4310.  
  4311.  
  4312.  -----------------------------------------------------------------------------
  4313.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 77
  4314.  
  4315.  
  4316.  GLOSSARY
  4317.  -----------------------------------------------------------------------------
  4318.  
  4319.            API
  4320.  
  4321.            API  is  an   acronym  for  "Application   Program  Interface"   or
  4322.            "Application Programmer Interface". An API is a well-defined set of
  4323.            related  functions  or  procedures  that  can  be  called  from  an
  4324.            application program written  in a programming  language such as  C,
  4325.            C++, Pascal or BASIC. These functions are used to access a specific
  4326.            feature or set of features from within your program. The RegKey API
  4327.            consists of five  functions (RegKeyNewCodeSet(), RegKeyGenerate (),
  4328.            RegKeyValidate(),  RegKeyFileGenerate()  and  RegKeyFileValidate())
  4329.            which you  can use  to add  registration key  capabilities to  your
  4330.            programs. Another example of an APIs is the Microsoft Windows  API,
  4331.            which provide  Windows  programs  with access  to  screen  display,
  4332.            printing and other features which are managed by Windows.
  4333.  
  4334.  
  4335.  
  4336.            BRAND
  4337.  
  4338.            As an  alternative  to using  registration  keys, each  copy  of  a
  4339.            particular application can  be "branded" with  a particular  user's
  4340.            name. In this case,  the application's executable file(s)  contains
  4341.            the name of the one user  who is licensed to  use that copy of  the
  4342.            software, and that  name is usually  displayed at program  startup.
  4343.            Branding is  commonly used  in  commercial software  to  discourage
  4344.            illegal copying of  the software, as  the guilty  user's name  will
  4345.            appear on every illegal copy. This disadvantage of this approach is
  4346.            that it  requires the  author or  company selling  the software  to
  4347.            produce a unique copy of the program for each user.
  4348.  
  4349.  
  4350.  
  4351.            CODE SET
  4352.  
  4353.            RegKey uses the  term "code  set" to refer  to a  set comprising a
  4354.            "generation code" and a corresponding  "validation code". For each
  4355.            application (or each version of the application) using RegKey  that
  4356.            requires unique  registration  keys, the  application  developer(s)
  4357.            generate a unique "code  set" using the  utilities included in  the
  4358.            RegKey package. The secret "generation code" is required to  create
  4359.            the unique  registration keys  for  a particular  application.  The
  4360.            "validation code" is used within the  application itself to test  a
  4361.            registration key provided by the user.
  4362.  
  4363.  
  4364.  
  4365.  
  4366.  
  4367.  
  4368.  -----------------------------------------------------------------------------
  4369.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 78
  4370.  
  4371.  
  4372.  
  4373.            ENCRYPTION
  4374.  
  4375.            Encryption is  the process  of translating  information -  such  as
  4376.            written text or  a computer program  - into a  form that cannot  be
  4377.            read by unauthorized  individuals. Only  by knowing  the manner  in
  4378.            which some information has been encrypted, can someone decrypt  and
  4379.            make use of that information. It  is possible to use an  encryption
  4380.            algorithm to encrypt portions of a program's executable file(s), in
  4381.            order to make it more difficult for someone to alter the executable
  4382.            file. This can be  of use when using  RegKey, in order to  increase
  4383.            the security of the RegKey mechanism.
  4384.  
  4385.            RegKey  does  not  provide  any  encryption  capabilities   itself.
  4386.            Depending upon where you live and  what form of encryption you  are
  4387.            using, there may be legal issues  you wish to consider if your  are
  4388.            going to  export  software  using encryption  technology  to  other
  4389.            countries.
  4390.  
  4391.  
  4392.  
  4393.            FILE-BASED REGISTRATION KEYS
  4394.  
  4395.            RegKey supports  two types  of registration  keys -  file-base  and
  4396.            user-entered.  With   file-based   registration  keys,   both   the
  4397.            registration string (e.g. the  user's name) and  the corresponding
  4398.            registration key code are stored in a registration key file. When a
  4399.            user becomes registered, they receive a small registration key file
  4400.            that is installed in the program's working directory. When a  valid
  4401.            registration key  file  is present,  the  program will  operate  in
  4402.            registered mode.
  4403.  
  4404.  
  4405.  
  4406.            GENERATION CODE
  4407.  
  4408.            RegKey uses the term  "generation code" to refer  to the numerical
  4409.            key that is  used to generate  registration keys  for a  particular
  4410.            application using  RegKey.  For  each  different  generation  code,
  4411.            different registration keys are generated for the same registration
  4412.            string.  Without  knowing   the  generation  code   used  by   your
  4413.            application,  it  is  infeasible   for  anyone  else  to   generate
  4414.            registration keys that  will work with  your application. For  this
  4415.            reason, you  should  take great  care  to keep  your  application's
  4416.            generation code a secret. You can  use the KeyGen utility included
  4417.            with RegKey to create a new generation code. When a generation code
  4418.            is created, a corresponding "validation  code" is also created.  It
  4419.            is  this  validation  code  that  is  passed  to  RegKey  by   your
  4420.            application when testing the validity of a registration key. It  is
  4421.            not usually  important to  keep the  validation code  a secret,  as
  4422.            knowing it  only  allows someone  to  determine whether  or  not  a
  4423.  
  4424.  -----------------------------------------------------------------------------
  4425.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 79
  4426.  
  4427.  
  4428.            particular registration key  / registration  string combination  is
  4429.            valid for your application.
  4430.  
  4431.  
  4432.  
  4433.            INFEASIBLE
  4434.  
  4435.            The term "infeasible"  is used in  software protection to  describe
  4436.            something that  is very  difficult -  though  not impossible  -  to
  4437.            achieve. For  instance,  even if  someone  were able  to  test  one
  4438.            million registration  keys per  second, it  would still  take  many
  4439.            centuries to discover  a RegKey  registration key  by a  trial-and-
  4440.            error method. Since so  much time would be  required to discover  a
  4441.            RegKey registration key by this method, it is said to be infeasible
  4442.            to "guess" a correct registration key.
  4443.  
  4444.  
  4445.  
  4446.            REGISTERED MODE
  4447.  
  4448.            Programs that use  registration key systems  may operate in  either
  4449.            "registered"  or   "unregistered"   mode.  In   "unregistered"   or
  4450.            "demonstration"  mode,  the  software  may  have  certain  features
  4451.            disabled, may only  operate for a  limited period of  time, or  may
  4452.            display a "please register" message during program operation.  When
  4453.            the user pays  for the software,  they receive  a registration  key
  4454.            corresponding to  their name  or other  personal information.  When
  4455.            this registration key is presented to the application, it will then
  4456.            operate  in  "registered"  mode,  eliminating  any   "unregistered"
  4457.            messages and possibly enabling additional features.
  4458.  
  4459.  
  4460.  
  4461.            REGISTRATION KEY
  4462.  
  4463.            For each  user  who pays  for  your  software, you  use  RegKey  to
  4464.            generate a unique registration key, based on the information of the
  4465.            registration  string  (usually  the  user's  name).  The  resulting
  4466.            registration key is a  96-bit number that  is (in all  probability)
  4467.            unique  for  each  user  that  registers  your  application.   This
  4468.            registration key may either be entered into your application by the
  4469.            user, or may be stored in  a "registration key file" that is  given
  4470.            to the user upon registration. Your application can then use RegKey
  4471.            to determine whether  or not the  registration key  is valid,  thus
  4472.            determining whether or not it should operate in "registered  mode".
  4473.            RegKey represents  the  registration key  as  a 20  digit  base  32
  4474.            number. The  registration  key  returned  to  you  when  generating
  4475.            registration  keys,  and  the  key  presented  to  RegKey  by  your
  4476.            application, is represented  as a 20  character string of  numerals
  4477.            and uppercase  letters.  Hence,  AB7EWBR24LZTUFEY2PLF  might  be  a
  4478.            typical RegKey registration key.
  4479.  
  4480.  -----------------------------------------------------------------------------
  4481.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 80
  4482.  
  4483.  
  4484.  
  4485.  
  4486.  
  4487.            REGISTRATION KEY FILE
  4488.  
  4489.            When file-based registration keys  are used, both the  registration
  4490.            string (usually the user's name) and the registration key code  are
  4491.            stored in a small  registration key file. This  file usually has  a
  4492.            .KEY filename extension.
  4493.  
  4494.  
  4495.  
  4496.            REGISTRATION STRING
  4497.  
  4498.            A unique  registration  string is  associated  with each  user  who
  4499.            registers your software. This  registration string is usually  just
  4500.            the user or organization's name, but it may also include additional
  4501.            information, such as the registered version or registration  expiry
  4502.            date. In  any case,  the registration  string usually  consists  of
  4503.            information that the user knows prior to registering. When the user
  4504.            pays for your software, you use  RegKey to generate a  registration
  4505.            key  that  corresponds  to   the  registration  string.  When   the
  4506.            registration string is presented to your application in conjunction
  4507.            with the registration key, it can  use RegKey to test the  validity
  4508.            of the registration string / registration key combination, in order
  4509.            to determine whether or not to operate in "registered mode".
  4510.  
  4511.  
  4512.  
  4513.            SHAREWARE
  4514.  
  4515.            A  method  of  marketing   computer  software,  where  the   author
  4516.            encourages the  free  distribution  of the  software.  This  allows
  4517.            potential users  of the  software to  "test-drive" the  application
  4518.            before buying it. In the shareware approach to software marketing,
  4519.            the user  is usually  required to  either stop  using the  software
  4520.            after a three to four week  trial period, or pay to "register"  the
  4521.            software with the author.
  4522.  
  4523.  
  4524.  
  4525.            SOFTWARE PROTECTION
  4526.  
  4527.            The term "software protection" is used to describe any mechanism or
  4528.            scheme  that  is   used  to  prevent   or  discourage  illegal   or
  4529.            unauthorized use  of  computer  software.  Approaches  to  software
  4530.            protection  include  "copy-protection"  schemes  which  attempt  to
  4531.            prevent a  duplicate  copy of  the  software from  being  produced,
  4532.            "hardware-key"  mechanisms  which  require  a  particular  hardware
  4533.            device (which is sold with the software) to be present in order  to
  4534.  
  4535.  
  4536.  -----------------------------------------------------------------------------
  4537.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 81
  4538.  
  4539.  
  4540.            use the  software, and  "registration-key"  mechanisms such  as  is
  4541.            provided by RegKey.
  4542.  
  4543.  
  4544.  
  4545.            USER-ENTERED REGISTRATION KEYS
  4546.  
  4547.            RegKey supports  two types  of registration  keys -  file-base  and
  4548.            user-entered.  With  user-entered   registration  keys,  the   user
  4549.            manually enters registration string (e.g. the user's name)  and the
  4550.            corresponding  registration  key  code  into  the  application   or
  4551.            configuration program  when  they  first  register.  When  a  valid
  4552.            registration key  has been  entered  for the  entered  registration
  4553.            string, the program will operate in registered mode.
  4554.  
  4555.  
  4556.  
  4557.            UNREGISTERED MODE
  4558.  
  4559.            See "Registered Mode".
  4560.  
  4561.  
  4562.  
  4563.            VALIDATION CODE
  4564.  
  4565.            RegKey uses the term  "validation code"  to refer  to the numerical
  4566.            key that  is used  to test  the validity  of a  registration key  /
  4567.            registration  string   combination,   during   your   application's
  4568.            execution. Your application should pass its unique validation  code
  4569.            to RegKey when it  wishes to test a  registration key. You can  use
  4570.            the KeyGen utility included with RegKey to create a new  validation
  4571.            code /  generation code set  for  a new  application (or  version).
  4572.            Unlike the generation code that should be kept confidential, it  is
  4573.            not usually important to keep the validation code a secret. This is
  4574.            because  knowing  the  validation  code  only  allows  someone   to
  4575.            determine  whether   or   not   a   particular   registration   key
  4576.            /registration string  combination is  valid for  your  application.
  4577.            Knowing the validation  code does  not enable  someone to  generate
  4578.            false registration keys for your application.
  4579.  
  4580.  
  4581.  
  4582.  
  4583.  
  4584.  
  4585.  
  4586.  
  4587.  
  4588.  
  4589.  
  4590.  
  4591.  
  4592.  -----------------------------------------------------------------------------
  4593.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 82
  4594.  
  4595.  
  4596.  INDEX
  4597.  -----------------------------------------------------------------------------
  4598.  
  4599.  
  4600.  
  4601.                 - A -                                    - I -
  4602.  
  4603.  API, 29, 31, 34, 78                      Introduction, 3, 23
  4604.   C/C++, 55
  4605.   QuickBASIC/Visual Basic, 61                            - K -
  4606.   Turbo Pascal, 69
  4607.  Applications of Registration Keys,       KeyGen Program, 13, 18, 19, 27, 28,
  4608.   22                                       29, 30, 31, 32, 37, 41, 51, 52,
  4609.  Author's address, 71                      54, 57, 58, 60, 65, 66, 68, 73,
  4610.                                            74, 75, 79, 82
  4611.                 - B -
  4612.                                                          - O -
  4613.  Branding Software, 22, 78
  4614.                                           Ordering RegKey
  4615.                 - C -                      Agreement, 17
  4616.                                            Filling Order Form, 8
  4617.  Code Sets, 23, 24, 27, 28, 29, 30,        Order Form, 15
  4618.   37, 38, 51, 57, 65, 78, 82               Overview, 7
  4619.  Common Problems, 44                       Price, 11
  4620.  CTL3DV2.DLL File, 19, 27, 44, 73,         Source Code, 13
  4621.   74, 75                                   Terms, 17
  4622.  
  4623.                 - E -                                    - P -
  4624.  
  4625.  Encryption, 79                           Porting RegKey, 13, 70
  4626.  Evaluation Terms, 5                      Principles of RegKey, 23
  4627.  Expiry Information, 23, 26, 32, 37,      Printing Manual, 1
  4628.   38, 39, 41, 52, 54, 58, 60, 66,
  4629.   68, 81                                                 - Q -
  4630.  
  4631.                 - F -                     QuickBASIC, 3, 19, 36, 45, 47, 56,
  4632.                                            57, 58, 59, 60, 61, 74
  4633.  Features of RegKey, 3
  4634.  File-Base Registration Keys, 79                         - R -
  4635.  File-Based Registration Keys, 25, 81
  4636.  Files, 73                                Registered Mode, 21, 36, 40, 80
  4637.                                           Registering RegKey. See Ordering
  4638.                 - G -                     Registration Key Expiry, 23, 26, 32,
  4639.                                            37, 38, 39, 41, 52, 54, 58, 60,
  4640.  Generating Registration Keys, 31          66, 68, 81
  4641.  Generation Codes, 4, 23, 29, 30, 31,     Registration Keys, 21, 23, 80
  4642.   32, 33, 41, 42, 44, 51, 52, 54,         Registration Strings, 23, 25, 26,
  4643.   57, 58, 60, 65, 66, 68, 78, 79, 82       31, 32, 33, 34, 35, 36, 37, 38,
  4644.  Getting Help, 44, 71                      39, 42, 52, 53, 54, 55, 58, 59,
  4645.  Glossary, 78                              60, 61, 66, 67, 68, 69, 79, 80,
  4646.                                            81, 82
  4647.  
  4648.  -----------------------------------------------------------------------------
  4649.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 83
  4650.  
  4651.  
  4652.  RegKey Files, 73                                        - T -
  4653.  RegKeyFileGenerate() Function, 33,
  4654.   52, 54, 58, 60, 66, 68, 78              Table Of Contents, 2, 18, 47
  4655.  RegKeyFileValidate() Function, 34,       Troubleshooting, 44
  4656.   35, 36, 44, 49, 53, 55, 59, 61,         Turbo Pascal, 3, 19, 36, 45, 47, 63,
  4657.   67, 69, 78                               64, 65, 66, 67, 68, 69, 74
  4658.  RegKeyGenerate() Function, 33, 52,
  4659.   54, 58, 60, 66, 68, 78                                 - U -
  4660.  RegKeyNewCodeSet() Function, 29, 51,
  4661.   52, 53, 54, 55, 57, 58, 59, 60,         Unregistered Mode, 21, 36, 40, 82
  4662.   61, 65, 66, 67, 68, 69, 78              User-Entered Registration Keys, 25,
  4663.  RegKeyValidate() Function, 34, 35,        82
  4664.   36, 42, 44, 49, 53, 55, 59, 61,
  4665.   67, 69, 78                                             - V -
  4666.  
  4667.                 - S -                     Validation Codes, 4, 23, 24, 27, 28,
  4668.                                            29, 30, 34, 35, 37, 42, 44, 51,
  4669.  Security, 4, 6, 12, 13, 21, 27, 40,       53, 55, 57, 59, 61, 65, 67, 69,
  4670.   79                                       78, 79, 82
  4671.  Shareware, 21, 22, 81                    Visual Basic, 3, 19, 36, 42, 46, 47,
  4672.  Software Protection, 43, 81               56, 57, 58, 59, 60, 61, 62, 75
  4673.  
  4674.  
  4675.  
  4676.  
  4677.  
  4678.  
  4679.  
  4680.  
  4681.  
  4682.  
  4683.  
  4684.  
  4685.  
  4686.  
  4687.  
  4688.  
  4689.  
  4690.  
  4691.  
  4692.  
  4693.  
  4694.  
  4695.  
  4696.  
  4697.  
  4698.  
  4699.  
  4700.  
  4701.  
  4702.  
  4703.  
  4704.  -----------------------------------------------------------------------------
  4705.  REGISTRATION KEY SYSTEM 3.10 MANUAL                            END OF PAGE 84
  4706.